changeset 43363:2ded39ef5bf7 stable

py3: fix exception message encoding in infinitepush Differential Revision: https://phab.mercurial-scm.org/D7195
author Emmanuel Leblond <emmanuel.leblond@gmail.com>
date Fri, 01 Nov 2019 17:39:17 +0100
parents ddfd0f3956f4
children dd64e229c46b
files hgext/infinitepush/__init__.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/infinitepush/__init__.py	Fri Nov 01 10:57:31 2019 -0700
+++ b/hgext/infinitepush/__init__.py	Fri Nov 01 17:39:17 2019 +0100
@@ -959,7 +959,7 @@
             service,
             eventtype=b'failure',
             elapsedms=(time.time() - start) * 1000,
-            errormsg=str(e),
+            errormsg=stringutil.forcebytestr(e),
             **kwargs
         )
         raise
@@ -1223,7 +1223,7 @@
             scratchbranchparttype,
             eventtype=b'failure',
             elapsedms=(time.time() - parthandlerstart) * 1000,
-            errormsg=str(e),
+            errormsg=stringutil.forcebytestr(e),
         )
         raise
     finally: