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
--- 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