##// END OF EJS Templates
localrepo: filter unknown nodes from the phasecache on destroyed...
Idan Kamara -
r18221:082d6929 default
parent child Browse files
Show More
@@ -1425,6 +1425,18 b' class localrepository(object):'
1425 cache.update(self, ctxgen)
1425 cache.update(self, ctxgen)
1426 cache.write(self)
1426 cache.write(self)
1427
1427
1428 # When one tries to:
1429 # 1) destroy nodes thus calling this method (e.g. strip)
1430 # 2) use phasecache somewhere (e.g. commit)
1431 #
1432 # then 2) will fail because the phasecache contains nodes that were
1433 # removed. We can either remove phasecache from the filecache,
1434 # causing it to reload next time it is accessed, or simply filter
1435 # the removed nodes now and write the updated cache.
1436 if '_phasecache' in self._filecache:
1437 self._phasecache.filterunknown(self)
1438 self._phasecache.write()
1439
1428 # Ensure the persistent tag cache is updated. Doing it now
1440 # Ensure the persistent tag cache is updated. Doing it now
1429 # means that the tag cache only has to worry about destroyed
1441 # means that the tag cache only has to worry about destroyed
1430 # heads immediately after a strip/rollback. That in turn
1442 # heads immediately after a strip/rollback. That in turn
@@ -578,7 +578,6 b' Commit and show expansion in original an'
578 $ hg --debug commit -ma2c -d '1 0' -u 'User Name <user@example.com>'
578 $ hg --debug commit -ma2c -d '1 0' -u 'User Name <user@example.com>'
579 c
579 c
580 c: copy a:0045e12f6c5791aac80ca6cbfd97709a88307292
580 c: copy a:0045e12f6c5791aac80ca6cbfd97709a88307292
581 removing unknown node 40a904bbbe4c from 1-phase boundary
582 overwriting c expanding keywords
581 overwriting c expanding keywords
583 committed changeset 2:25736cf2f5cbe41f6be4e6784ef6ecf9f3bbcc7d
582 committed changeset 2:25736cf2f5cbe41f6be4e6784ef6ecf9f3bbcc7d
584 $ cat a c
583 $ cat a c
@@ -749,7 +748,6 b' Commit with multi-line message and custo'
749
748
750 $ hg --debug commit -l log -d '2 0' -u 'User Name <user@example.com>'
749 $ hg --debug commit -l log -d '2 0' -u 'User Name <user@example.com>'
751 a
750 a
752 removing unknown node 40a904bbbe4c from 1-phase boundary
753 overwriting a expanding keywords
751 overwriting a expanding keywords
754 committed changeset 2:bb948857c743469b22bbf51f7ec8112279ca5d83
752 committed changeset 2:bb948857c743469b22bbf51f7ec8112279ca5d83
755 $ rm log
753 $ rm log
General Comments 0
You need to be logged in to leave comments. Login now