Mercurial > public > mercurial-scm > hg-stable
diff mercurial/hg.py @ 44060:a61287a95dc3
core: migrate uses of hashlib.sha1 to hashutil.sha1
Differential Revision: https://phab.mercurial-scm.org/D7849
author | Augie Fackler <augie@google.com> |
---|---|
date | Mon, 13 Jan 2020 17:15:14 -0500 |
parents | be8552f25cab |
children | abcc82bf0717 |
line wrap: on
line diff
--- a/mercurial/hg.py Mon Jan 13 17:14:19 2020 -0500 +++ b/mercurial/hg.py Mon Jan 13 17:15:14 2020 -0500 @@ -9,7 +9,6 @@ from __future__ import absolute_import import errno -import hashlib import os import shutil import stat @@ -48,7 +47,7 @@ verify as verifymod, vfs as vfsmod, ) - +from .utils import hashutil from .interfaces import repository as repositorymod release = lock.release @@ -738,7 +737,7 @@ ) elif sharenamemode == b'remote': sharepath = os.path.join( - sharepool, node.hex(hashlib.sha1(source).digest()) + sharepool, node.hex(hashutil.sha1(source).digest()) ) else: raise error.Abort(