obshistory: import 'node' as 'nodemod'
authorPierre-Yves David <pierre-yves.david@octobus.net>
Thu, 18 May 2017 11:29:23 +0200
changeset 2406 31255706b591
parent 2405 4ff849709fea
child 2407 783a74c60a5e
obshistory: import 'node' as 'nodemod' This simplify the next changeset.
hgext3rd/evolve/obshistory.py
--- a/hgext3rd/evolve/obshistory.py	Thu May 18 11:00:06 2017 +0200
+++ b/hgext3rd/evolve/obshistory.py	Thu May 18 11:29:23 2017 +0200
@@ -8,7 +8,7 @@
 # GNU General Public License version 2 or any later version.
 
 from mercurial import (
-    node
+    node as nodemod,
 )
 
 def _debugobshistorysingle(fm, repo, revs):
@@ -63,7 +63,7 @@
     fm.plain('\n')
 
 def _debugobshistorydisplaymissingctx(fm, nodewithoutctx):
-    hexnode = node.short(nodewithoutctx)
+    hexnode = nodemod.short(nodewithoutctx)
     fm.startitem()
     fm.write('debugobshistory.node', '%s', hexnode,
              label="evolve.node evolve.missing_change_ctx")
@@ -97,7 +97,7 @@
     if len(succnodes) > 0:
         fm.plain(' as ')
 
-        shortsnodes = (node.short(succnode) for succnode in sorted(succnodes))
+        shortsnodes = (nodemod.short(succnode) for succnode in sorted(succnodes))
         nodes = fm.formatlist(shortsnodes, 'debugobshistory.succnodes', sep=', ')
         fm.write('debugobshistory.succnodes', '%s', nodes,
                  label="evolve.node")