Mercurial > evolve
diff hgext/evolve.py @ 1294:d1c29db2e055
prune: fix pruning w/ bookmarks and inhibit
Previously prune would create the obsolesence markers, then try to fix up the
bookmarks. With inhibit enabled, the act of closing a transaction for the
bookmark step caused it to unhide commits that were trying to be pruned.
The fix is to put the whole thing in a transaction.
author | Durham Goode <durham@fb.com> |
---|---|
date | Tue, 07 Apr 2015 14:26:03 -0700 |
parents | 35d8789ea7a8 |
children | 1ac05eef72ca |
line wrap: on
line diff
--- a/hgext/evolve.py Tue Apr 07 14:08:18 2015 -0700 +++ b/hgext/evolve.py Tue Apr 07 14:26:03 2015 -0700 @@ -1801,6 +1801,7 @@ try: wlock = repo.wlock() lock = repo.lock() + tr = repo.transaction('prune') # defines pruned changesets precs = [] revs.sort() @@ -1891,7 +1892,11 @@ updatebookmarks = _bookmarksupdater(repo, ctx.node()) updatebookmarks(dest.node()) break + + tr.close() finally: + if tr: + tr.release() lockmod.release(lock, wlock) @command('amend|refresh',