This revision was automatically updated to reflect the committed changes. Closed by commit rHG148f64bcb6de: py3: replace __str__ to __bytes__ in hgext/journal.py (authored by pulkit, committed by ).
REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D2616?vs=6500&id=6504 REVISION DETAIL https://phab.mercurial-scm.org/D2616 AFFECTED FILES hgext/journal.py CHANGE DETAILS diff --git a/hgext/journal.py b/hgext/journal.py --- a/hgext/journal.py +++ b/hgext/journal.py @@ -24,6 +24,7 @@ bookmarks, cmdutil, dispatch, + encoding, error, extensions, hg, @@ -219,15 +220,17 @@ (timestamp, tz), user, command, namespace, name, oldhashes, newhashes) - def __str__(self): - """String representation for storage""" + def __bytes__(self): + """bytes representation for storage""" time = ' '.join(map(str, self.timestamp)) oldhashes = ','.join([node.hex(hash) for hash in self.oldhashes]) newhashes = ','.join([node.hex(hash) for hash in self.newhashes]) return '\n'.join(( time, self.user, self.command, self.namespace, self.name, oldhashes, newhashes)) + __str__ = encoding.strmethod(__bytes__) + class journalstorage(object): """Storage for journal entries To: pulkit, #hg-reviewers, indygreg Cc: mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel