Patchwork D2674: transaction: fix an error string with bytestr() on a repr()d value

login
register
mail settings
Submitter phabricator
Date March 4, 2018, 10:10 p.m.
Message ID <4c943453277e2bdf1a7b60c1158435d4@localhost.localdomain>
Download mbox | patch
Permalink /patch/29018/
State Not Applicable
Headers show

Comments

phabricator - March 4, 2018, 10:10 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGef345f9e4295: transaction: fix an error string with bytestr() on a repr()d value (authored by durin42, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D2674?vs=6626&id=6630

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

AFFECTED FILES
  contrib/python3-whitelist
  mercurial/transaction.py

CHANGE DETAILS




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

Patch

diff --git a/mercurial/transaction.py b/mercurial/transaction.py
--- a/mercurial/transaction.py
+++ b/mercurial/transaction.py
@@ -18,6 +18,7 @@ 
 from .i18n import _
 from . import (
     error,
+    pycompat,
     util,
 )
 
@@ -604,7 +605,8 @@ 
             f, o = l.split('\0')
             entries.append((f, int(o), None))
         except ValueError:
-            report(_("couldn't read journal entry %r!\n") % l)
+            report(
+                _("couldn't read journal entry %r!\n") % pycompat.bytestr(l))
 
     backupjournal = "%s.backupfiles" % file
     if opener.exists(backupjournal):
diff --git a/contrib/python3-whitelist b/contrib/python3-whitelist
--- a/contrib/python3-whitelist
+++ b/contrib/python3-whitelist
@@ -347,6 +347,7 @@ 
 test-revlog-packentry.t
 test-revset-dirstate-parents.t
 test-revset-outgoing.t
+test-rollback.t
 test-run-tests.py
 test-schemes.t
 test-serve.t