mercurial/utils/hashutil.py
author Pierre-Yves David <pierre-yves.david@octobus.net>
Sun, 18 Jul 2021 22:49:26 +0200
changeset 47717 d905eff405d1
parent 46413 521ac0d7047f
child 48966 6000f5b25c9b
permissions -rw-r--r--
mq: replace usage of `normal` with newer API Differential Revision: https://phab.mercurial-scm.org/D11159

from __future__ import absolute_import

import hashlib

try:
    from ..thirdparty import sha1dc  # pytype: disable=import-error

    sha1 = sha1dc.sha1
except (ImportError, AttributeError):
    sha1 = hashlib.sha1