# HG changeset patch # User Pierre-Yves David # Date 1344332145 -7200 # Node ID 1c82147e93959a2cc7965bf4fa665c502ebf6f25 # Parent b86e062f233596ad44607a20e1ea8fd80e7aada3 obsolete: remove 2.2 compat hack diff -r b86e062f2335 -r 1c82147e9395 hgext/obsolete.py --- a/hgext/obsolete.py Mon Aug 06 19:34:24 2012 +0200 +++ b/hgext/obsolete.py Tue Aug 07 11:35:45 2012 +0200 @@ -72,14 +72,9 @@ from mercurial import cmdutil from mercurial import templatekw from mercurial import obsolete +from mercurial.localrepo import storecache obsolete._enabled = True -try: - from mercurial.localrepo import storecache - storecache('babar') # to trigger import -except (TypeError, ImportError): - def storecache(*args): - return scmutil.filecache(*args, instore=True) ### Patch changectx @@ -600,8 +595,7 @@ def uisetup(ui): extensions.wrapcommand(commands.table, "update", wrapmayobsoletewc) extensions.wrapcommand(commands.table, "pull", wrapmayobsoletewc) - if util.safehasattr(cmdutil, 'amend'): - extensions.wrapfunction(cmdutil, 'amend', wrapcmdutilamend) + extensions.wrapfunction(cmdutil, 'amend', wrapcmdutilamend) extensions.wrapfunction(discovery, 'checkheads', wrapcheckheads) extensions.wrapfunction(phases, 'advanceboundary', wrapclearcache)