# HG changeset patch # User Martin von Zweigbergk # Date 1515969557 28800 # Node ID 54074a82e050fed818231a4d94e286f446d84d15 # Parent 5748f404dad3d4cc084624e4886c481c4fba8d99 repair: filter out unknown revisions from phasecache within transaction I'm about to add another summary report callback that needs to access phase information. These callbacks run at the end of the transaction and some of them failed because they tried to get the phase for stripped commits. The solution is to filter out unknown revisions before the transaction is closed. Differential Revision: https://phab.mercurial-scm.org/D1865 diff -r 5748f404dad3 -r 54074a82e050 mercurial/repair.py --- a/mercurial/repair.py Sun Jan 14 23:37:06 2018 -0800 +++ b/mercurial/repair.py Sun Jan 14 14:39:17 2018 -0800 @@ -203,8 +203,8 @@ deleteobsmarkers(repo.obsstore, stripobsidx) del repo.obsstore + repo._phasecache.filterunknown(repo) - repo._phasecache.filterunknown(repo) if tmpbundlefile: ui.note(_("adding branch\n")) f = vfs.open(tmpbundlefile, "rb")