firefoxreleases: bump minimum version requirement; r=sheehan
authorGregory Szorc <gps@mozilla.com>
Tue, 22 May 2018 19:36:09 +0000
changeset 5985 759bff2dff9b6e41a1b2766f18e2fa12a45e659c
parent 5984 97c68eb25ad2574f06815a4398e1335fd52af4aa
child 5986 03eeb833e3845a3aa9b1f862496a81af317b5c86
push id2840
push usergszorc@mozilla.com
push dateTue, 22 May 2018 20:30:07 +0000
treeherderversion-control-tools@759bff2dff9b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssheehan
firefoxreleases: bump minimum version requirement; r=sheehan We only run this extension on hgweb, which is currently running Mercurial 4.4. We can safely drop support for old versions and the compatibility code that came with it. We still maintain support for Mercurial 4.3 because that's what the local testing virtualenv is running. Hopefully that will get bumped to 4.4 soon. Differential Revision: https://phabricator.services.mozilla.com/D1343
hgext/firefoxreleases/__init__.py
--- a/hgext/firefoxreleases/__init__.py
+++ b/hgext/firefoxreleases/__init__.py
@@ -3,51 +3,48 @@
 
 """Expose Firefox release information."""
 
 import collections
 import os
 
 from mercurial.i18n import _
 from mercurial import (
+    configitems,
     error,
     extensions,
     registrar,
     revset,
-    util,
 )
 from mercurial.hgweb import (
     webcommands,
     webutil,
 )
 
 OUR_DIR = os.path.normpath(os.path.dirname(__file__))
 execfile(os.path.join(OUR_DIR, '..', 'bootstrap.py'))
 
 import mozautomation.releasedb as releasedb
 
 from mozhg.util import (
-    import_module,
     is_firefox_repo,
 )
 
-# TRACKING hg43
-configitems = import_module('mercurial.configitems')
 
-minimumhgversion = '4.1'
-testedwith = '4.1 4.2 4.3 4.4'
+minimumhgversion = '4.3'
+testedwith = '4.3 4.4'
 
-if util.safehasattr(registrar, 'configitem'):
-    configtable = {}
-    configitem  = registrar.configitem(configtable)
+configtable = {}
+configitem  = registrar.configitem(configtable)
 
-    configitem('mozilla', 'enablefirefoxreleases',
-               default=configitems.dynamicdefault)
-    configitem('mozilla', 'firefoxreleasesdb',
-               default=configitems.dynamicdefault)
+configitem('mozilla', 'enablefirefoxreleases',
+           default=configitems.dynamicdefault)
+configitem('mozilla', 'firefoxreleasesdb',
+           default=configitems.dynamicdefault)
+
 
 def extsetup(ui):
     extensions.wrapfunction(webutil, 'changesetentry', changesetentry)
 
     setattr(webcommands, 'firefoxreleases', firefox_releases_web_command)
     webcommands.__all__.append('firefoxreleases')
 
     # TODO remove once we can use @revsetpredicate from extensions