Skip to content
Snippets Groups Projects

Topic/stable/evolve split nonlinear

Closed Pierre-Yves David requested to merge topic/stable/evolve-split-nonlinear into branch/default
16 files
+ 235
40
Compare changes
  • Side-by-side
  • Inline
Files
16
@@ -844,7 +844,12 @@ def buildpullobsmarkersboundaries(pullop, bundle2=True):
repo = pullop.repo
remote = pullop.remote
unfi = repo.unfiltered()
revs = unfi.revs(b'::(%ln - null)', pullop.common)
# Also exclude filtered revisions. Working on unfiltered repository can
# give a bit more precise view of the repository. However it makes the
# overall operation more complicated.
filteredrevs = repo.changelog.filteredrevs
# XXX probably not very efficient
revs = unfi.revs(b'::(%ln - null) - %ld', pullop.common, filteredrevs)
boundaries = {b'heads': pullop.pulledsubset}
if not revs: # nothing common
boundaries[b'common'] = [node.nullid]
@@ -859,8 +864,14 @@ def buildpullobsmarkersboundaries(pullop, bundle2=True):
if bundle2 and _canobshashrange(repo, remote):
obsexcmsg(repo.ui, b"looking for common markers in %i nodes\n"
% len(revs))
boundaries[b'missing'] = findmissingrange(repo.ui, unfi, pullop.remote,
revs)
missing = findmissingrange(repo.ui, repo, pullop.remote, revs)
boundaries[b'missing'] = missing
# using getattr since `limitedarguments` is missing
# hg <= 5.0 (69921d02daaf)
if getattr(pullop.remote, 'limitedarguments', False):
# prepare for a possible fallback to common
common = repo.set("heads(only(%ld, %ln))", revs, missing)
boundaries[b'common'] = [c.node() for c in common]
else:
boundaries[b'common'] = [node.nullid]
return boundaries
Loading