diff --git a/mercurial/bookmarks.py b/mercurial/bookmarks.py --- a/mercurial/bookmarks.py +++ b/mercurial/bookmarks.py @@ -181,6 +181,7 @@ class bmstore(dict): for name, node in self.iteritems(): fp.write("%s %s\n" % (hex(node), encoding.fromlocal(name))) self._clean = True + self._repo.invalidatevolatilesets() def expandname(self, bname): if bname == '.': diff --git a/tests/test-obsolete.t b/tests/test-obsolete.t --- a/tests/test-obsolete.t +++ b/tests/test-obsolete.t @@ -1009,11 +1009,9 @@ bookmarks change $ echo "hello" > b $ hg commit --amend -m "message" $ hg book bookb -r 13bedc178fce --hidden - cache inconsistency $ hg log -r 13bedc178fce 5:13bedc178fce (draft) [ bookb] add b $ hg book -d bookb - cache inconsistency $ hg log -r 13bedc178fce abort: hidden revision '13bedc178fce'! (use --hidden to access hidden revisions)