[PATCH 1 of 4] formatter: use stringutil.pprint() in debug output to drop b''
Yuya Nishihara
yuya at tcha.org
Sun Oct 14 06:21:37 UTC 2018
# HG changeset patch
# User Yuya Nishihara <yuya at tcha.org>
# Date 1539492679 -7200
# Sun Oct 14 06:51:19 2018 +0200
# Node ID b28a63d39d280a081a2de1f96c5c7276aef6a0e1
# Parent 8783710b1d58d2ccc0f611904af244a1dde214d4
formatter: use stringutil.pprint() in debug output to drop b''
diff --git a/mercurial/formatter.py b/mercurial/formatter.py
--- a/mercurial/formatter.py
+++ b/mercurial/formatter.py
@@ -129,7 +129,10 @@ from . import (
templateutil,
util,
)
-from .utils import dateutil
+from .utils import (
+ dateutil,
+ stringutil,
+)
pickle = util.pickle
@@ -321,7 +324,7 @@ class debugformatter(baseformatter):
self._out = out
self._out.write("%s = [\n" % self._topic)
def _showitem(self):
- self._out.write(' %s,\n' % pycompat.byterepr(self._item))
+ self._out.write(' %s,\n' % stringutil.pprint(self._item))
def end(self):
baseformatter.end(self)
self._out.write("]\n")
More information about the Mercurial-devel
mailing list