Bug 1305795 - Sort buildbot properties for logging; r?ted
Not really related to the task at hand. But my brain was angry
I had to read unsorted buildbot properties in log files as part
of reverse engineering what mozharness is doing.
MozReview-Commit-ID: HcglRXImXCA
--- a/testing/mozharness/mozharness/mozilla/buildbot.py
+++ b/testing/mozharness/mozharness/mozilla/buildbot.py
@@ -63,17 +63,17 @@ class BuildbotMixin(object):
# TODO try/except?
self.buildbot_config = parse_config_file(c['buildbot_json_path'])
buildbot_properties = copy.deepcopy(self.buildbot_config.get('properties', {}))
if 'commit_titles' in buildbot_properties:
# Remove the commit messages since they can cause false positives with
# Treeherder log parsers. Eg: "Bug X - Fix TEST-UNEPXECTED-FAIL ...".
del buildbot_properties['commit_titles']
self.info("Using buildbot properties:")
- self.info(json.dumps(buildbot_properties, indent=4))
+ self.info(json.dumps(buildbot_properties, indent=4, sort_keys=True))
def tryserver_email(self):
pass
def buildbot_status(self, tbpl_status, level=None, set_return_code=True):
if tbpl_status not in TBPL_STATUS_DICT:
self.error("buildbot_status() doesn't grok the status %s!" % tbpl_status)
else: