Bug 1333255: only apply seta optimizations for tests; r=jonasfj
MozReview-Commit-ID: FoIlgwBe4Gd
--- a/taskcluster/taskgraph/optimize.py
+++ b/taskcluster/taskgraph/optimize.py
@@ -201,20 +201,16 @@ def opt_index_search(task, params, index
return False, None
@optimization('seta')
def opt_seta(task, params):
bbb_task = False
- # no need to call SETA for build jobs
- if task.task.get('extra', {}).get('treeherder', {}).get('jobKind', '') == 'build':
- return False, None
-
# for bbb tasks we need to send in the buildbot buildername
if task.task.get('provisionerId', '') == 'buildbot-bridge':
label = task.task.get('payload').get('buildername')
bbb_task = True
else:
label = task.label
# we would like to return 'False, None' while it's high_value_task
--- a/taskcluster/taskgraph/transforms/task.py
+++ b/taskcluster/taskgraph/transforms/task.py
@@ -790,17 +790,16 @@ def add_files_changed(config, tasks):
yield task
@transforms.add
def setup_optimizations(config, tasks):
for task in tasks:
optimizations = task.setdefault('optimizations', [])
- optimizations.append(['seta'])
if 'when' in task and 'files-changed' in task['when']:
optimizations.append(['files-changed', task['when']['files-changed']])
yield task
@transforms.add
def build_task(config, tasks):
for task in tasks:
--- a/taskcluster/taskgraph/transforms/tests.py
+++ b/taskcluster/taskgraph/transforms/tests.py
@@ -654,16 +654,17 @@ def make_job_description(config, tests):
jobdesc['when'] = test.get('when', {})
jobdesc['attributes'] = attributes
jobdesc['dependencies'] = {'build': build_label}
jobdesc['expires-after'] = test['expires-after']
jobdesc['routes'] = []
jobdesc['run-on-projects'] = test.get('run-on-projects', ['all'])
jobdesc['scopes'] = []
jobdesc['tags'] = test.get('tags', {})
+ jobdesc['optimizations'] = [['seta']] # always run SETA for tests
jobdesc['extra'] = {
'chunks': {
'current': test['this-chunk'],
'total': test['chunks'],
},
'suite': {
'name': suite,
'flavor': flavor,