diff mercurial/hg.py @ 35582:72b91f905065

py3: use node.hex(h.digest()) instead of h.hexdigest() hashlib.sha1.hexdigest() returns str on Python 3. Differential Revision: https://phab.mercurial-scm.org/D1792
author Pulkit Goyal <7895pulkit@gmail.com>
date Fri, 29 Dec 2017 05:25:27 +0530
parents bdae51a83dfb
children c751b9fdbc40
line wrap: on
line diff
--- a/mercurial/hg.py	Fri Dec 29 05:22:06 2017 +0530
+++ b/mercurial/hg.py	Fri Dec 29 05:25:27 2017 +0530
@@ -569,7 +569,7 @@
                             'unable to resolve identity of remote)\n'))
         elif sharenamemode == 'remote':
             sharepath = os.path.join(
-                sharepool, hashlib.sha1(source).hexdigest())
+                sharepool, node.hex(hashlib.sha1(source).digest()))
         else:
             raise error.Abort(_('unknown share naming mode: %s') %
                               sharenamemode)