changeset 35372:073bc922d349

py3: handle keyword arguments correctly in templater.py Differential Revision: https://phab.mercurial-scm.org/D1645
author Pulkit Goyal <7895pulkit@gmail.com>
date Sun, 10 Dec 2017 04:49:53 +0530
parents c999d246e48c
children 4e377c43e80b
files mercurial/templater.py
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/templater.py	Sun Dec 10 04:49:40 2017 +0530
+++ b/mercurial/templater.py	Sun Dec 10 04:49:53 2017 +0530
@@ -880,7 +880,7 @@
     if len(args) == 1:
         pattern = evalstring(context, mapping, args[0])
 
-    return templatekw.showlatesttags(pattern, **mapping)
+    return templatekw.showlatesttags(pattern, **pycompat.strkwargs(mapping))
 
 @templatefunc('localdate(date[, tz])')
 def localdate(context, mapping, args):
@@ -1063,7 +1063,8 @@
             revs = list(revs)
             revsetcache[raw] = revs
 
-    return templatekw.showrevslist("revision", revs, **mapping)
+    return templatekw.showrevslist("revision", revs,
+                                   **pycompat.strkwargs(mapping))
 
 @templatefunc('rstdoc(text, style)')
 def rstdoc(context, mapping, args):