util: convert traceback-related sysstrs to sysbytes in getstackframes
authorAugie Fackler <augie@google.com>
Mon, 12 Feb 2018 20:44:06 -0500
changeset 36130 7ec26f27ca83
parent 36129 2874896a6e3b
child 36131 ce9f1c32810b
util: convert traceback-related sysstrs to sysbytes in getstackframes With this change, test-devel-warnings.t passes except for differences in how ProgrammingError is formatted and one mysterious traceback inside of transaction.__del__. Differential Revision: https://phab.mercurial-scm.org/D2212
mercurial/util.py
--- a/mercurial/util.py	Mon Feb 12 20:43:33 2018 -0500
+++ b/mercurial/util.py	Mon Feb 12 20:44:06 2018 -0500
@@ -3171,7 +3171,7 @@
 
     Not be used in production code but very convenient while developing.
     '''
-    entries = [(fileline % (fn, ln), func)
+    entries = [(fileline % (pycompat.sysbytes(fn), ln), pycompat.sysbytes(func))
         for fn, ln, func, _text in traceback.extract_stack()[:-skip - 1]
         ][-depth:]
     if entries: