D3158: histedit: look up partial nodeid as partial nodeid

2018-04-08 Thread martinvonz (Martin von Zweigbergk)
martinvonz updated this revision to Diff 7879. REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D3158?vs=7783=7879 REVISION DETAIL https://phab.mercurial-scm.org/D3158 AFFECTED FILES hgext/histedit.py CHANGE DETAILS diff --git a/hgext/histedit.py

D3158: histedit: look up partial nodeid as partial nodeid

2018-04-07 Thread martinvonz (Martin von Zweigbergk)
martinvonz added a comment. In https://phab.mercurial-scm.org/D3158#51161, @indygreg wrote: > +1 to having a new function to handle cases for things like partial match. I agree, that seems much better. REPOSITORY rHG Mercurial REVISION DETAIL

D3158: histedit: look up partial nodeid as partial nodeid

2018-04-07 Thread indygreg (Gregory Szorc)
indygreg added a comment. +1 to having a new function to handle cases for things like partial match. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D3158 To: martinvonz, durin42, #hg-reviewers, indygreg Cc: yuja, indygreg, mercurial-devel

D3158: histedit: look up partial nodeid as partial nodeid

2018-04-07 Thread yuja (Yuya Nishihara)
yuja added inline comments. INLINE COMMENTS > yuja wrote in histedit.py:446 > Nah. It's for performance reason on ambiguous case, radix tree lookup vs > linear search. I've sent a patch to fix the inconsistency, > but it was rejected because of that. > > Maybe we'll need a scmutil function to

D3158: histedit: look up partial nodeid as partial nodeid

2018-04-07 Thread yuja (Yuya Nishihara)
yuja added inline comments. INLINE COMMENTS > martinvonz wrote in histedit.py:446 > > If the previous code worked on on the filtered repo, shouldn't this code? > > The previous code just *looked like* it worked on the filtered repo :) This > is copied from changectx.__init__(), which is where

D3158: histedit: look up partial nodeid as partial nodeid

2018-04-06 Thread martinvonz (Martin von Zweigbergk)
martinvonz added inline comments. INLINE COMMENTS > indygreg wrote in histedit.py:446 > Err wait. Why is `repo.unfiltered()` being used here? If the previous code > worked on on the filtered repo, shouldn't this code? > > The side effect of this change is that a histedit rule could reference a

D3158: histedit: look up partial nodeid as partial nodeid

2018-04-06 Thread indygreg (Gregory Szorc)
indygreg requested changes to this revision. indygreg added inline comments. This revision now requires changes to proceed. INLINE COMMENTS > histedit.py:446 > ha = node.hex(self.node) > -try: > -self.node = repo[ha].node() > -except error.RepoError: > -

D3158: histedit: look up partial nodeid as partial nodeid

2018-04-06 Thread martinvonz (Martin von Zweigbergk)
martinvonz created this revision. Herald added a reviewer: durin42. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY I'm about to remove support for repo[]. In the verify() method, we know that self.node is always a partial or full binary