[PATCH evolve-ext] inhibit: fix _filterpublic

Laurent Charignon lcharignon at fb.com
Sun Jan 10 18:52:51 UTC 2016


# HG changeset patch
# User Laurent Charignon <lcharignon at fb.com>
# Date 1452451944 28800
#      Sun Jan 10 10:52:24 2016 -0800
# Node ID 99776fd528c036da95325291faf61d2e0eb2835b
# Parent  4f83b2d2d20de55b2a63910ff10204af9106fd26
inhibit: fix _filterpublic

Before this patch, _filterpublic would always filter rep._obsinhibit and not
its "nodes" argument. Fortunately, we always called it with repo._obsinhibit as
its "nodes" argument!

diff --git a/hgext/inhibit.py b/hgext/inhibit.py
--- a/hgext/inhibit.py
+++ b/hgext/inhibit.py
@@ -122,7 +122,7 @@
     Public changesets are already immune to obsolescence"""
     getrev = repo.changelog.nodemap.get
     getphase = repo._phasecache.phase
-    return (n for n in repo._obsinhibit
+    return (n for n in nodes
             if getrev(n) is not None and getphase(repo, getrev(n)))
 
 def _inhibitmarkers(repo, nodes):


More information about the Mercurial-devel mailing list