Patchwork D1645: py3: handle keyword arguments correctly in templater.py

login
register
mail settings
Submitter phabricator
Date Dec. 10, 2017, 2:51 a.m.
Message ID <7d17a53342f70ab6f26abbd4b7dc98b4@localhost.localdomain>
Download mbox | patch
Permalink /patch/26191/
State Not Applicable
Headers show

Comments

phabricator - Dec. 10, 2017, 2:51 a.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG073bc922d349: py3: handle keyword arguments correctly in templater.py (authored by pulkit, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D1645?vs=4324&id=4336

REVISION DETAIL
  https://phab.mercurial-scm.org/D1645

AFFECTED FILES
  mercurial/templater.py

CHANGE DETAILS




To: pulkit, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/mercurial/templater.py b/mercurial/templater.py
--- a/mercurial/templater.py
+++ b/mercurial/templater.py
@@ -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):