changeset 19615:77d434760857

obsolete: allow passing a revision to successorssets()
author Dan Villiom Podlaski Christiansen <danchr@gmail.com>
date Sun, 04 Aug 2013 13:43:39 +0200
parents 1d50c69c1f0a
children f959b60e3025
files mercurial/obsolete.py
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/obsolete.py	Mon Aug 12 17:44:31 2013 -0500
+++ b/mercurial/obsolete.py	Sun Aug 04 13:43:39 2013 +0200
@@ -496,6 +496,9 @@
     for its live spawn. Code that makes multiple calls to `successorssets`
     *must* use this cache mechanism or suffer terrible performances."""
 
+    if isinstance(initialnode, int):
+        initialnode = repo.unfiltered().changelog.node(initialnode)
+
     succmarkers = repo.obsstore.successors
 
     # Stack of nodes we search successors sets for