D2176: py3: convert traceback representation to bytes when logging

indygreg (Gregory Szorc) phabricator at mercurial-scm.org
Mon Feb 12 21:48:36 EST 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rHG9446246e4d1a: py3: convert traceback representation to bytes when logging (authored by indygreg, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D2176?vs=5477&id=5598

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

AFFECTED FILES
  mercurial/dispatch.py

CHANGE DETAILS

diff --git a/mercurial/dispatch.py b/mercurial/dispatch.py
--- a/mercurial/dispatch.py
+++ b/mercurial/dispatch.py
@@ -992,6 +992,7 @@
     this function returns False, ignored otherwise.
     """
     warning = _exceptionwarning(ui)
-    ui.log("commandexception", "%s\n%s\n", warning, traceback.format_exc())
+    ui.log("commandexception", "%s\n%s\n", warning,
+           pycompat.sysbytes(traceback.format_exc()))
     ui.warn(warning)
     return False  # re-raise the exception



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


More information about the Mercurial-devel mailing list