Mercurial > hg-stable
changeset 35417:83014fa95435
rebase: fix for hgsubversion
5c25fe7fb1e broke something in the hgsubversion test path, causing it raise an
abort (Abort: nothing to merge) during a perfectly good rebase. I tracked it
down to this change. It's probably not hgsubversion related.
I suspect that using the same `wctx` from before the initial update causes
problems with the wctx's cached manifest property. I noticed we also sometimes
stick random gunk on the wctx object in other places (like in `copies.py`) so
it's probably best to reset it for now.
The line I added before was actually useless since we don't pass wctx to the
initial `merge.update`, so it defaults to `repo[None]`. So I just removed it.
Differential Revision: https://phab.mercurial-scm.org/D1679
author | Phil Cohen <phillco@fb.com> |
---|---|
date | Tue, 12 Dec 2017 22:05:21 -0800 |
parents | f84b01257e06 |
children | 0fe5d99804bb |
files | hgext/rebase.py |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/rebase.py Mon Dec 11 15:43:56 2017 +0800 +++ b/hgext/rebase.py Tue Dec 12 22:05:21 2017 -0800 @@ -1102,13 +1102,14 @@ if wctx.isinmemory(): wctx.setbase(repo[p1]) else: - # This is necessary to invalidate workingctx's caches. - wctx = repo[None] if repo['.'].rev() != p1: repo.ui.debug(" update to %d:%s\n" % (p1, repo[p1])) mergemod.update(repo, p1, False, True) else: repo.ui.debug(" already in destination\n") + # This is, alas, necessary to invalidate workingctx's manifest cache, + # as well as other data we litter on it in other places. + wctx = repo[None] repo.dirstate.write(repo.currenttransaction()) repo.ui.debug(" merge against %d:%s\n" % (rev, repo[rev])) if base is not None: