--- a/hgext/evolve.py Tue Oct 23 17:12:53 2012 +0200
+++ b/hgext/evolve.py Tue Oct 23 17:13:19 2012 +0200
@@ -29,18 +29,11 @@
try:
from mercurial import obsolete
+ getattr(obsolete, 'getrevs') # 2.4 specific
if not obsolete._enabled:
obsolete._enabled = True
-except ImportError:
- raise util.Abort('Evolve extension requires Mercurial 2.3 (or later)')
-
-try:
- getattr(obsolete, 'getrevs') # 2.4 specific
- raise util.Abort('Your version of Mercurial is too recent for this '
- 'version of evolve',
- hint="upgrade your evolve")
-except AttributeError:
- pass
+except (ImportError, AttributeError):
+ raise util.Abort('Evolve extension requires Mercurial 2.4 (or later)')
from mercurial import bookmarks