D6469: bookmarks: use correct store for "ambiguity check"
martinvonz (Martin von Zweigbergk)
phabricator at mercurial-scm.org
Sat Jun 1 05:48:15 UTC 2019
martinvonz created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
I still don't quite know what the check does, but I clearly got it
wrong in https://phab.mercurial-scm.org/rHG526750cdd02d39cc718bc2ab2b89f909d007be4b (bookmarks: keep bookmarks in .hg/store if new
config set, 2019-05-15). Just compare with the strings we use in
@repofilecache and @storecache. These bugs were then copied to the
stable branch in https://phab.mercurial-scm.org/rHGc2b83c957621b67251e08e75be7805e4227795f6 (localrepo: grab mixedrepostorecache
class from https://phab.mercurial-scm.org/rHG526750cdd02d39cc718bc2ab2b89f909d007be4b, 2019-05-20) and https://phab.mercurial-scm.org/rHG2338bdea44744312e42632d68bc00491184c748b (bookmark: also
make bookmark cache depends of the changelog, 2019-05-20). As a
result, test-wireproto-exchangev2.t is flaky on both branches. This
patch fixes that.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D6469
AFFECTED FILES
mercurial/localrepo.py
CHANGE DETAILS
diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py
--- a/mercurial/localrepo.py
+++ b/mercurial/localrepo.py
@@ -133,10 +133,10 @@
def join(self, obj, fnameandlocation):
fname, location = fnameandlocation
- if location == '':
+ if location == 'plain':
return obj.vfs.join(fname)
else:
- if location != 'store':
+ if location != '':
raise error.ProgrammingError('unexpected location: %s' %
location)
return obj.sjoin(fname)
@@ -1219,8 +1219,8 @@
cls = repoview.newtype(self.unfiltered().__class__)
return cls(self, name, visibilityexceptions)
- @mixedrepostorecache(('bookmarks', ''), ('bookmarks.current', ''),
- ('00changelog.i', 'store'))
+ @mixedrepostorecache(('bookmarks', 'plain'), ('bookmarks.current', 'plain'),
+ ('00changelog.i', ''))
def _bookmarks(self):
return bookmarks.bmstore(self)
To: martinvonz, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list