Bug 1428912 - Only keep track of job names for seen configs in build_lints. r=dustin
authorMike Hommey <mh+mozilla@glandium.org>
Tue, 09 Jan 2018 07:56:36 +0900
changeset 452751 13dc722140a01c7d7be08db431f4f9fd2bd16e3d
parent 452750 5786d2b246ee6cb20309b41cc1fba25c33953bcf
child 452752 301f76fcc84c99831afd52d2f8e2ac88cc31623c
push id1648
push usermtabara@mozilla.com
push dateThu, 01 Mar 2018 12:45:47 +0000
treeherdermozilla-release@cbb9688c2eeb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdustin
bugs1428912
milestone59.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1428912 - Only keep track of job names for seen configs in build_lints. r=dustin When looking for perfherder data collection duplicates, we currently keep full job objects references, which are then used in case an error occurs, to display the job names of the duplicates. But those job objects are yielded and may be modified by other transforms, and presently, by the time a duplicate is found, the corresponding job object has been modified such that it has no 'name' key anymore, leading to a KeyError exception when trying to display the duplicate error message. So instead of keeping the job objects, which can change, and which we don't have a real use for, just keep the job name.
taskcluster/taskgraph/transforms/build_lints.py
--- a/taskcluster/taskgraph/transforms/build_lints.py
+++ b/taskcluster/taskgraph/transforms/build_lints.py
@@ -46,13 +46,13 @@ def check_mozharness_perfherder_options(
         assert primary_config.startswith('builds/')
 
         key = (platform, primary_config, nightly, options)
 
         if key in seen_configs:
             raise Exception('Non-unique Perfherder data collection for jobs '
                             '%s and %s: set PERFHERDER_EXTRA_OPTIONS in worker '
                             'environment variables or use different mozconfigs'
-                            % (job['name'], seen_configs[key]['name']))
+                            % (job['name'], seen_configs[key]))
 
-        seen_configs[key] = job
+        seen_configs[key] = job['name']
 
         yield job