[PATCH] rebase: only clear rebase status after the rebase transaction has completed
Laurent Charignon
lcharignon at fb.com
Thu Dec 3 16:37:33 UTC 2015
# HG changeset patch
# User Laurent Charignon <lcharignon at fb.com>
# Date 1449160280 28800
# Thu Dec 03 08:31:20 2015 -0800
# Node ID 44bf2c5e5e9676c6709698df6eff1890c9947dfb
# Parent 91905c0c47377520eebdedcfa6bcb73b77e24e0c
rebase: only clear rebase status after the rebase transaction has completed
In 405320cd6198, I made the mistake of moving the step "clearing the status
after a rebase" to inside the rebase transaction.
This was wrong, since we don't want to clear the status (and the rebase state)
if something went wrong during the transaction: if something goes wrong we
want to keep the rebase state to be able to abort.
It broke rebase with evolve + inhibit.
diff --git a/hgext/rebase.py b/hgext/rebase.py
--- a/hgext/rebase.py
+++ b/hgext/rebase.py
@@ -563,10 +563,10 @@ def rebase(ui, repo, **opts):
if activebookmark not in repo._bookmarks:
# active bookmark was divergent one and has been deleted
activebookmark = None
- clearstatus(repo)
tr.close()
finally:
release(tr)
+ clearstatus(repo)
ui.note(_("rebase completed\n"))
util.unlinkpath(repo.sjoin('undo'), ignoremissing=True)
More information about the Mercurial-devel
mailing list