Patchwork D3831: py3: use stringutil.pprint() to print NoneType

login
register
mail settings
Submitter phabricator
Date June 25, 2018, 12:01 p.m.
Message ID <03a9ff5a1cf6c4f8fc5f0f68b559ebf2@localhost.localdomain>
Download mbox | patch
Permalink /patch/32409/
State Not Applicable
Headers show

Comments

phabricator - June 25, 2018, 12:01 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGa0c3d83d5f04: py3: use stringutil.pprint() to print NoneType (authored by pulkit, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D3831?vs=9276&id=9278

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

AFFECTED FILES
  mercurial/debugcommands.py
  tests/test-debugcommands.t

CHANGE DETAILS




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

Patch

diff --git a/tests/test-debugcommands.t b/tests/test-debugcommands.t
--- a/tests/test-debugcommands.t
+++ b/tests/test-debugcommands.t
@@ -337,7 +337,7 @@ 
 
 #if no-windows
   $ hg debugcolor --style --color always | egrep 'mode|style|log\.'
-  color mode: ansi
+  color mode: 'ansi'
   available style:
   \x1b[0;33mlog.changeset\x1b[0m:                      \x1b[0;33myellow\x1b[0m (esc)
 #endif
diff --git a/mercurial/debugcommands.py b/mercurial/debugcommands.py
--- a/mercurial/debugcommands.py
+++ b/mercurial/debugcommands.py
@@ -427,7 +427,7 @@ 
         'hg debugcolor')
 def debugcolor(ui, repo, **opts):
     """show available color, effects or style"""
-    ui.write(('color mode: %s\n') % ui._colormode)
+    ui.write(('color mode: %s\n') % stringutil.pprint(ui._colormode))
     if opts.get(r'style'):
         return _debugdisplaystyle(ui)
     else: