# HG changeset patch # User Pierre-Yves David # Date 1489263308 28800 # Node ID 9f7ce656bfdf9a37cc9a74396b0a240ac68b2059 # Parent 0c23715426879a85dedafb8770d53226390ed1df depth: use lower lever function to compute missing The time spend parsing the revset is noticeable. diff -r 0c2371542687 -r 9f7ce656bfdf hgext3rd/evolve/utility.py --- a/hgext3rd/evolve/utility.py Sat Mar 11 10:26:30 2017 -0800 +++ b/hgext3rd/evolve/utility.py Sat Mar 11 12:15:08 2017 -0800 @@ -47,7 +47,7 @@ # multiple ancestors, we pick the highest and search all missing bits anc = max(cl.rev(a) for a in ancs) revdepth = depth(repo, anc) - revdepth += len(repo.revs('only(%d, %d)', rev, anc)) + revdepth += len(cl.findmissingrevs(common=[anc], heads=[rev])) _depthcache[n] = revdepth # actual_depth = len(list(cl.ancestors([rev], inclusive=True))) # assert revdepth == actual_depth, (rev, revdepth, actual_depth)