[PATCH 13 of 27 clfilter V2] clfilter: `bookmark.validdest` should run on unfiltered repo

Pierre-Yves David pierre-yves.david at ens-lyon.org
Mon Oct 8 16:38:04 CDT 2012


# HG changeset patch
# User Pierre-Yves David <pierre-yves.david at ens-lyon.org>
# Date 1349709983 -7200
# Node ID 3a48d439e796a94bafc197dbb819d1e11df40167
# Parent  4d3b4de3810fba4ea8e259dfdb96ce5aab816247
clfilter: `bookmark.validdest` should run on unfiltered repo

The logic recently added to `bookmark.validdest` is about using data about
obsolete changeset to check if a bookmark destination is valide. Obsolete
changesets are likely to be filtered so we need to work on unfiltered
repository.

diff --git a/mercurial/bookmarks.py b/mercurial/bookmarks.py
--- a/mercurial/bookmarks.py
+++ b/mercurial/bookmarks.py
@@ -255,6 +255,7 @@
 
 def validdest(repo, old, new):
     """Is the new bookmark destination a valid update from the old one"""
+    repo = repo.unfiltered()
     if old == new:
         # Old == new -> nothing to update.
         return False


More information about the Mercurial-devel mailing list