[PATCH 1 of 6] py3: decode bytes before logging in run-tests.py
Yuya Nishihara
yuya at tcha.org
Mon Oct 21 09:40:24 EDT 2019
On Mon, 21 Oct 2019 12:00:53 +0200, Denis Laxalde wrote:
> # HG changeset patch
> # User Denis Laxalde <denis at laxalde.org>
> # Date 1571650001 -7200
> # Mon Oct 21 11:26:41 2019 +0200
> # Node ID f6d36e1d008ac5eaaccfaeb2a598cdbdf1d36391
> # Parent d0f89e8c615aca23f169c228a86f4f77fa4dbb67
> py3: decode bytes before logging in run-tests.py
> @@ -3111,12 +3111,16 @@ class TestRunner(object):
> 'extensions.logexceptions=%s' % logexceptions.decode('utf-8')
> )
>
> - vlog("# Using TESTDIR", self._testdir)
> - vlog("# Using RUNTESTDIR", osenvironb[b'RUNTESTDIR'])
> - vlog("# Using HGTMP", self._hgtmp)
> + vlog("# Using TESTDIR", self._testdir.decode("utf-8"))
> + vlog("# Using RUNTESTDIR", osenvironb[b'RUNTESTDIR'].decode("utf-8"))
> + vlog("# Using HGTMP", self._hgtmp.decode("utf-8"))
> vlog("# Using PATH", os.environ["PATH"])
> - vlog("# Using", IMPL_PATH, osenvironb[IMPL_PATH])
> - vlog("# Writing to directory", self._outputdir)
> + vlog(
> + "# Using",
> + IMPL_PATH.decode("utf-8"),
> + osenvironb[IMPL_PATH].decode("utf-8"),
> + )
> + vlog("# Writing to directory", self._outputdir.decode("utf-8"))
Maybe better to use _strpath() for paths.
More information about the Mercurial-devel
mailing list