# HG changeset patch # User Pierre-Yves David # Date 1643653738 -3600 # Node ID 3f618484eeb60467988cd97f18edc61ff18e486e # Parent 6ed7ee9f44dbda2d1c8c93504a04cd750a9426be transaction: add a way to know a transaction has been finalized This will be useful to fix the timing of the branchmap on disk caching. Differential Revision: https://phab.mercurial-scm.org/D12127 diff -r 6ed7ee9f44db -r 3f618484eeb6 mercurial/transaction.py --- a/mercurial/transaction.py Tue Feb 01 15:14:05 2022 +0100 +++ b/mercurial/transaction.py Mon Jan 31 19:28:58 2022 +0100 @@ -229,6 +229,10 @@ if self._journal: self._abort() + @property + def finalized(self): + return self._finalizecallback is None + @active def startgroup(self): """delay registration of file entry