Bug 1337903: add and use a job_try_name attribute; r=ahal

This fixes the ability to run mozbase via `-j mozbase`, with the
added advantage that it will obey `-p` too.

MozReview-Commit-ID: 1zkitUephXk
This commit is contained in:
Dustin J. Mitchell
2017-03-08 17:28:34 +00:00
parent 4e3b3f8b2f
commit ebf4711d4e
3 changed files with 23 additions and 6 deletions

View File

@@ -58,6 +58,13 @@ def validate(config, jobs):
"In job {!r}:".format(job['name']))
@transforms.add
def set_job_try_name(config, jobs):
for job in jobs:
job.setdefault('attributes', {}).setdefault('job_try_name', job['name'])
yield job
@transforms.add
def expand_platforms(config, jobs):
for job in jobs:
@@ -98,8 +105,7 @@ def handle_platform(config, jobs):
build_platform, build_type = platform.split('/')
attributes = job.setdefault('attributes', {})
attributes.update({
job['attributes'].update({
'build_platform': build_platform,
'build_type': build_type,
})