| OLD | NEW |
| 1 # Copyright 2008 Google Inc. | 1 # Copyright 2008 Google Inc. |
| 2 # | 2 # |
| 3 # Licensed under the Apache License, Version 2.0 (the "License"); | 3 # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 # you may not use this file except in compliance with the License. | 4 # you may not use this file except in compliance with the License. |
| 5 # You may obtain a copy of the License at | 5 # You may obtain a copy of the License at |
| 6 # | 6 # |
| 7 # http://www.apache.org/licenses/LICENSE-2.0 | 7 # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 # | 8 # |
| 9 # Unless required by applicable law or agreed to in writing, software | 9 # Unless required by applicable law or agreed to in writing, software |
| 10 # distributed under the License is distributed on an "AS IS" BASIS, | 10 # distributed under the License is distributed on an "AS IS" BASIS, |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 247 | 247 |
| 248 properties = build.get('properties') or {} | 248 properties = build.get('properties') or {} |
| 249 properties.update({ | 249 properties.update({ |
| 250 'issue': issue.key.id(), | 250 'issue': issue.key.id(), |
| 251 'master': build['master'], | 251 'master': build['master'], |
| 252 'patch_project': issue.project, | 252 'patch_project': issue.project, |
| 253 'patch_storage': 'rietveld', | 253 'patch_storage': 'rietveld', |
| 254 'patchset': patchset_id, | 254 'patchset': patchset_id, |
| 255 'rietveld': 'https://%s' % self_hostname, | 255 'rietveld': 'https://%s' % self_hostname, |
| 256 }) | 256 }) |
| 257 if 'presubmit' in build['builder'].lower(): |
| 258 properties['dry_run'] = 'true' |
| 257 req['builds'].append({ | 259 req['builds'].append({ |
| 258 'bucket': 'master.%s' % build['master'], | 260 'bucket': 'master.%s' % build['master'], |
| 259 'parameters_json': json.dumps({ | 261 'parameters_json': json.dumps({ |
| 260 'builder_name': build['builder'], | 262 'builder_name': build['builder'], |
| 261 'changes': [change], | 263 'changes': [change], |
| 262 'properties': properties, | 264 'properties': properties, |
| 263 }), | 265 }), |
| 264 'tags': [ | 266 'tags': [ |
| 265 'builder:%s' % build['builder'], | 267 'builder:%s' % build['builder'], |
| 266 'buildset:%s' % get_buildset_for( | 268 'buildset:%s' % get_buildset_for( |
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 412 logging.error( | 414 logging.error( |
| 413 'Preferred domain name for this app is not set. ' | 415 'Preferred domain name for this app is not set. ' |
| 414 'See PREFERRED_DOMAIN_NAMES in settings.py: %r', hostname) | 416 'See PREFERRED_DOMAIN_NAMES in settings.py: %r', hostname) |
| 415 raise ndb.Return([]) | 417 raise ndb.Return([]) |
| 416 | 418 |
| 417 return BUILDSET_TAG_FORMAT.format( | 419 return BUILDSET_TAG_FORMAT.format( |
| 418 hostname=hostname, | 420 hostname=hostname, |
| 419 issue=issue_id, | 421 issue=issue_id, |
| 420 patch=patchset_id, | 422 patch=patchset_id, |
| 421 ) | 423 ) |
| OLD | NEW |