Bug 1175655 - mozharness should use full hg revision; r=jlund
authorMike Shal <mshal@mozilla.com>
Tue, 28 Jul 2015 14:41:10 -0400
changeset 287226 88eead104033b65c3e09455ab467c3997d49dab7
parent 287225 57273aac79962211eb4317a34dce786bae066ddf
child 287227 70dfc7ced3037e7f515d9dc346a24174a2d7bc11
push id5067
push userraliiev@mozilla.com
push dateMon, 21 Sep 2015 14:04:52 +0000
treeherdermozilla-beta@14221ffe5b2f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjlund
bugs1175655
milestone42.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 1175655 - mozharness should use full hg revision; r=jlund
testing/mozharness/mozharness/mozilla/building/buildb2gbase.py
testing/mozharness/mozharness/mozilla/building/buildbase.py
testing/mozharness/scripts/spidermonkey_build.py
--- a/testing/mozharness/mozharness/mozilla/building/buildb2gbase.py
+++ b/testing/mozharness/mozharness/mozilla/building/buildb2gbase.py
@@ -188,17 +188,17 @@ class B2GBuildBaseScript(BuildbotMixin, 
                 )
             elif repo_type == 'git':
                 git = self.query_exe('git', return_type='list')
                 revision = self.get_output_from_command(
                     git + ['rev-parse', 'HEAD'], cwd=repo
                 )
             else:
                 return None
-        return revision[0:12] if revision else None
+        return revision
 
     def query_gecko_config_path(self):
         conf_file = self.config.get('gecko_config')
         if conf_file is None:
             conf_file = os.path.join(
                 'b2g', 'config',
                 self.config.get('b2g_config_dir', self.config['target']),
                 'config.json'
--- a/testing/mozharness/mozharness/mozilla/building/buildbase.py
+++ b/testing/mozharness/mozharness/mozilla/building/buildbase.py
@@ -1133,17 +1133,17 @@ or run without that action (ie: --no-{ac
                 source_path = dirs['abs_src_dir']  # let's take the default
 
             # Look at what we have checked out
             if os.path.exists(source_path):
                 hg = self.query_exe('hg', return_type='list')
                 revision = self.get_output_from_command(
                     hg + ['parent', '--template', '{node|short}'], cwd=source_path
                 )
-        return revision[0:12].encode('ascii', 'replace') if revision else None
+        return revision.encode('ascii', 'replace') if revision else None
 
     def _checkout_source(self):
         """use vcs_checkout to grab source needed for build."""
         # TODO make this method its own action
         c = self.config
         dirs = self.query_abs_dirs()
         repo = self._query_repo()
         vcs_checkout_kwargs = {
--- a/testing/mozharness/scripts/spidermonkey_build.py
+++ b/testing/mozharness/scripts/spidermonkey_build.py
@@ -215,17 +215,17 @@ class SpidermonkeyBuild(MockMixin,
             revision = self.buildbot_properties['revision']
         elif self.buildbot_config and 'sourcestamp' in self.buildbot_config:
             revision = self.buildbot_config['sourcestamp']['revision']
         else:
             # Useful for local testing. In actual use, this would always be
             # None.
             revision = self.config.get('revision')
 
-        return revision[0:12] if revision else None
+        return revision
 
     def query_branch(self):
         if self.buildbot_config and 'properties' in self.buildbot_config:
             return self.buildbot_config['properties']['branch']
         elif 'branch' in self.config:
             # Used for locally testing try vs non-try
             return self.config['branch']
         else: