Chromium Code Reviews| Index: appengine/cr-buildbucket/swarming/swarmingcfg.py |
| diff --git a/appengine/cr-buildbucket/swarming/swarmingcfg.py b/appengine/cr-buildbucket/swarming/swarmingcfg.py |
| index 4ff71914ccd85865579406a61463bfea6285ce94..a0b8c392148b33a4163255fb9621a57aaf332801 100644 |
| --- a/appengine/cr-buildbucket/swarming/swarmingcfg.py |
| +++ b/appengine/cr-buildbucket/swarming/swarmingcfg.py |
| @@ -30,7 +30,7 @@ def validate_dimensions(field_name, dimensions, ctx): |
| if len(components) != 2: |
| ctx.error('does not have ":"') |
| continue |
| - key, value = components |
| + key, _ = components |
| if not key: |
| ctx.error('no key') |
| else: |
| @@ -42,8 +42,6 @@ def validate_dimensions(field_name, dimensions, ctx): |
| ctx.error('duplicate key %s', key) |
| else: |
| known_keys.add(key) |
| - if not value: |
| - ctx.error('no value') |
|
tandrii(chromium)
2016/07/19 22:41:04
ok, so validator won't choke any more on empty val
nodir
2016/07/22 18:03:37
key
|
| def validate_recipe_cfg(recipe, common_recipe, ctx): |
| @@ -139,5 +137,6 @@ def validate_cfg(swarming, ctx): |
| b, ctx, bucket_has_pool_dim=has_pool_dim, |
| common_recipe=common_recipe) |
| + |
| def has_pool_dimension(dimensions): |
| return any(d.startswith('pool:') for d in dimensions) |