D10257: rebase: set `prepared = True` at very end of `_preparenewrebase()`
martinvonz (Martin von Zweigbergk)
phabricator at mercurial-scm.org
Wed Mar 24 06:25:35 UTC 2021
martinvonz created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.
REVISION SUMMARY
Once we've set `rebaseruntime.prepared = True`, `rebaseruntime.repo`
starts returning the unfiltered repo. That will make my next patch
break, because that patch moves the call to `rewriteutil.precheck()`
after the call to `_handleskippingobsolete()`, which current happens
after `prepared = True`. We therefore need to prepare by moving
`prepared = True` a bit later, after `_handleskippingobsolete()`. I
don't think that matters for that call.
REPOSITORY
rHG Mercurial
BRANCH
default
REVISION DETAIL
https://phab.mercurial-scm.org/D10257
AFFECTED FILES
hgext/rebase.py
CHANGE DETAILS
diff --git a/hgext/rebase.py b/hgext/rebase.py
--- a/hgext/rebase.py
+++ b/hgext/rebase.py
@@ -447,11 +447,11 @@
if dest.closesbranch() and not self.keepbranchesf:
self.ui.status(_(b'reopening closed branch head %s\n') % dest)
- self.prepared = True
-
# Calculate self.obsolete_* sets
self._handleskippingobsolete()
+ self.prepared = True
+
def _assignworkingcopy(self):
if self.inmemory:
from mercurial.context import overlayworkingctx
@@ -2192,7 +2192,6 @@
obsolete_with_successor_in_destination = {}
obsolete_with_successor_in_rebase_set = set()
- assert repo.filtername is None
cl = repo.changelog
get_rev = cl.index.get_rev
extinctrevs = set(repo.revs(b'extinct()'))
To: martinvonz, #hg-reviewers
Cc: mercurial-patches, mercurial-devel
More information about the Mercurial-devel
mailing list