# HG changeset patch # User Pulkit Goyal <7895pulkit@gmail.com> # Date 1497976906 -19800 # Node ID 30d0cb279bacf791577e90124b2a94018588f0b8 # Parent 4107eb8a5648ad31f7fb3e95bbc8999c73a94c49 py3: catch binascii.Error raised from binascii.unhexlify Before Python 3, binsacii.unhexlify used to raise TypeError, now it raises binascii.Error. diff -r 4107eb8a5648 -r 30d0cb279bac mercurial/revlog.py --- a/mercurial/revlog.py Tue Jun 20 23:39:59 2017 -0700 +++ b/mercurial/revlog.py Tue Jun 20 22:11:46 2017 +0530 @@ -13,6 +13,7 @@ from __future__ import absolute_import +import binascii import collections import errno import hashlib @@ -1094,7 +1095,7 @@ if maybewdir: raise error.WdirUnsupported return None - except TypeError: + except (TypeError, binascii.Error): pass def lookup(self, id):