durin42 created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers.
REVISION SUMMARY Lucky for us, the exception type exists on 2.7, so we can include it in the except block without any extra work. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D2244 AFFECTED FILES hgext/histedit.py CHANGE DETAILS diff --git a/hgext/histedit.py b/hgext/histedit.py --- a/hgext/histedit.py +++ b/hgext/histedit.py @@ -183,6 +183,7 @@ from __future__ import absolute_import +import binascii import errno import os @@ -425,7 +426,7 @@ rulehash = rule.strip().split(' ', 1)[0] try: rev = node.bin(rulehash) - except TypeError: + except (TypeError, binascii.Error): raise error.ParseError("invalid changeset %s" % rulehash) return cls(state, rev) To: durin42, #hg-reviewers Cc: mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel