[Updated] D10860: dog-raft: keep opts dict str-keyed a bit longer

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Mon Jun 21 12:16:38 UTC 2021


Closed by commit rHG5c49e0aa7fad: dog-raft: keep opts dict str-keyed a bit longer (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D10860?vs=28602&id=28633

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D10860/new/

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

AFFECTED FILES
  mercurial/commands.py

CHANGE DETAILS

diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -3088,8 +3088,7 @@
 
 
 def _dograft(ui, repo, *revs, **opts):
-    opts = pycompat.byteskwargs(opts)
-    if revs and opts.get(b'rev'):
+    if revs and opts.get('rev'):
         ui.warn(
             _(
                 b'warning: inconsistent use of --rev might give unexpected '
@@ -3098,12 +3097,13 @@
         )
 
     revs = list(revs)
-    revs.extend(opts.get(b'rev'))
+    revs.extend(opts.get('rev'))
     # a dict of data to be stored in state file
     statedata = {}
     # list of new nodes created by ongoing graft
     statedata[b'newnodes'] = []
 
+    opts = pycompat.byteskwargs(opts)
     cmdutil.resolvecommitoptions(ui, opts)
 
     editor = cmdutil.getcommiteditor(



To: martinvonz, #hg-reviewers, pulkit
Cc: mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20210621/298f8ec2/attachment-0002.html>


More information about the Mercurial-patches mailing list