changeset 1630:9a78ed4b9765

inhibit: use 'repo.revs' instead of 'repo.set' This skip the creation of a changectx object.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Tue, 17 Nov 2015 20:19:32 -0800
parents 74cf5a69f201
children f6d10432499d
files hgext/inhibit.py
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/inhibit.py
+++ b/hgext/inhibit.py
@@ -129,13 +129,14 @@
     if not _inhibitenabled(repo):
         return
 
-    newinhibit = list(repo.set('::%ln and obsolete()', nodes))
+    newinhibit = repo.revs('::%ln and obsolete()', nodes)
     if newinhibit:
+        node = repo.changelog.node
         lock = tr = None
         try:
             lock = repo.lock()
             tr = repo.transaction('obsinhibit')
-            repo._obsinhibit.update(c.node() for c in newinhibit)
+            repo._obsinhibit.update(node(r) for r in newinhibit)
             _schedulewrite(tr, _filterpublic(repo, repo._obsinhibit))
             repo.invalidatevolatilesets()
             tr.close()