Bug 1168979 part 5 - Add allowed_build_tasks to distinguish builds that require symbol uploading; r=mrrrgn

This commit is contained in:
Anthony Miyaguchi
2015-07-09 14:47:34 -07:00
parent 836ca82095
commit 16ce9e37da
3 changed files with 15 additions and 3 deletions

View File

@@ -374,10 +374,10 @@ class Graph(object):
message = '({}), extra.treeherder.collection must contain one type' message = '({}), extra.treeherder.collection must contain one type'
raise ValueError(message.fomrat(build['task'])) raise ValueError(message.fomrat(build['task']))
if 'post-build' in build: for post_build in build['post-build']:
# copy over the old parameters to update the template # copy over the old parameters to update the template
post_parameters = copy.copy(build_parameters) post_parameters = copy.copy(build_parameters)
post_task = configure_dependent_task(build['post-build']['task'], post_task = configure_dependent_task(post_build['task'],
post_parameters, post_parameters,
slugid(), slugid(),
templates, templates,

View File

@@ -259,10 +259,18 @@ def parse_commit(message, jobs):
else: else:
additional_parameters = {} additional_parameters = {}
# Generate list of post build tasks that run on this build
post_build_jobs = []
for job_flag in jobs['flags']['post-build']:
job = jobs['post-build'][job_flag]
if 'allowed_build_tasks' in job and build_task not in job['allowed_build_tasks']:
continue
post_build_jobs.append(copy.deepcopy(job))
# Node for this particular build type # Node for this particular build type
result.append({ result.append({
'task': build_task, 'task': build_task,
'post-build': jobs['post-build']['upload-symbols'], 'post-build': post_build_jobs,
'dependents': extract_tests_from_platform( 'dependents': extract_tests_from_platform(
jobs['tests'], platform_builds, build_task, tests jobs['tests'], platform_builds, build_task, tests
), ),

View File

@@ -179,6 +179,10 @@ builds:
post-build: post-build:
upload-symbols: upload-symbols:
allowed_build_tasks:
- tasks/builds/opt_linux64.yml
- tasks/builds/dbg_linux64.yml
- tasks/builds/android_api_11.yml
task: tasks/post-builds/upload_symbols.yml task: tasks/post-builds/upload_symbols.yml
tests: tests: