changeset 36456:9ff5cbfbc26a

py3: fix more keyword arguments handling Differential Revision: https://phab.mercurial-scm.org/D2476
author Pulkit Goyal <7895pulkit@gmail.com>
date Tue, 27 Feb 2018 14:41:24 +0530
parents 9e3cb58c7ab3
children 0e8b76644e20
files hgext/lfs/__init__.py hgext/narrow/narrowcommands.py mercurial/templatekw.py
diffstat 3 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/lfs/__init__.py	Tue Feb 27 14:28:17 2018 +0530
+++ b/hgext/lfs/__init__.py	Tue Feb 27 14:41:24 2018 +0530
@@ -385,6 +385,6 @@
          [('r', 'rev', [], _('upload large files introduced by REV'))])
 def debuglfsupload(ui, repo, **opts):
     """upload lfs blobs added by the working copy parent or given revisions"""
-    revs = opts.get('rev', [])
+    revs = opts.get(r'rev', [])
     pointers = wrapper.extractpointers(repo, scmutil.revrange(repo, revs))
     wrapper.uploadblobs(repo, pointers)
--- a/hgext/narrow/narrowcommands.py	Tue Feb 27 14:28:17 2018 +0530
+++ b/hgext/narrow/narrowcommands.py	Tue Feb 27 14:41:24 2018 +0530
@@ -122,8 +122,8 @@
 
         def pullbundle2extraprepare_widen(orig, pullop, kwargs):
             orig(pullop, kwargs)
-            if opts.get('depth'):
-                kwargs['depth'] = opts['depth']
+            if opts.get(r'depth'):
+                kwargs['depth'] = opts[r'depth']
         wrappedextraprepare = extensions.wrappedfunction(exchange,
             '_pullbundle2extraprepare', pullbundle2extraprepare_widen)
 
--- a/mercurial/templatekw.py	Tue Feb 27 14:28:17 2018 +0530
+++ b/mercurial/templatekw.py	Tue Feb 27 14:41:24 2018 +0530
@@ -791,7 +791,7 @@
 
         data.append({'successors': successors, 'markers': finalmarkers})
 
-    f = _showlist('succsandmarkers', data, args)
+    f = _showlist('succsandmarkers', data, pycompat.byteskwargs(args))
     return _hybrid(f, data, lambda x: x, pycompat.identity)
 
 @templatekeyword('p1rev')