Bug 1334667 - Distinguish nightlies for all build metrics, not just build times. r=wlach
MozReview-Commit-ID: IfSgjT5oDVY
--- a/testing/mozharness/mozharness/mozilla/building/buildbase.py
+++ b/testing/mozharness/mozharness/mozilla/building/buildbase.py
@@ -1861,24 +1861,20 @@ or run without that action (ie: --no-{ac
with open(p, 'rb') as fh:
resources = json.load(fh)
if 'duration' not in resources:
self.info('resource usage lacks duration; ignoring')
return None
- extra_options = self.perfherder_resource_options()
- if self.query_is_nightly():
- extra_options = ['nightly'] + extra_options
-
data = {
'name': 'build times',
'value': resources['duration'],
- 'extraOptions': extra_options,
+ 'extraOptions': self.perfherder_resource_options(),
'subtests': [],
}
for phase in resources['phases']:
if 'duration' not in phase:
continue
data['subtests'].append({
'name': phase['name'],
@@ -1997,16 +1993,23 @@ or run without that action (ie: --no-{ac
"alertThreshold": 0.25,
"subtests": size_measurements
})
build_metrics = self._load_build_resources()
if build_metrics:
perfherder_data['suites'].append(build_metrics)
+ if self.query_is_nightly:
+ for suite in perfherder_data['suites']:
+ if 'extraOptions' in suite:
+ suite['extraOptions'] = ['nightly'] + suite['extraOptions']
+ else:
+ suite['extraOptions'] = ['nightly']
+
if perfherder_data["suites"]:
self.info('PERFHERDER_DATA: %s' % json.dumps(perfherder_data))
def sendchange(self):
if os.environ.get('TASK_ID'):
self.info("We are not running this in buildbot; skipping")
return