commit: look-up new revision once
Look-up by node is slightly more expensive, so since it is necessary
more than once, do it explicitly.
Differential Revision: https://phab.mercurial-scm.org/D9830
from __future__ import absolute_importimport hashlibtry: from ..thirdparty import sha1dc sha1 = sha1dc.sha1except (ImportError, AttributeError): sha1 = hashlib.sha1