D3310: scmutil: use resolvepartialhexnodeid() from revsymbol()

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Fri Apr 13 18:00:37 UTC 2018


martinvonz created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  I should have copied this from changectx.__init__ into in https://phab.mercurial-scm.org/rHG35b34202dd3b2effc6e5ff5a82f911825a9cf532
  (context: handle partial nodeids in revsymbol(), 2018-04-08).

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D3310

AFFECTED FILES
  mercurial/scmutil.py

CHANGE DETAILS

diff --git a/mercurial/scmutil.py b/mercurial/scmutil.py
--- a/mercurial/scmutil.py
+++ b/mercurial/scmutil.py
@@ -503,7 +503,7 @@
         except KeyError:
             pass
 
-        node = repo.unfiltered().changelog._partialmatch(symbol)
+        node = resolvehexnodeidprefix(repo, symbol)
         if node is not None:
             rev = repo.changelog.rev(node)
             return repo[rev]



To: martinvonz, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list