[jhbuild] Compare bytes/str correctly in both python 2 & 3
- From: Christoph Reiter <creiter src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [jhbuild] Compare bytes/str correctly in both python 2 & 3
- Date: Fri, 26 Jun 2020 15:30:14 +0000 (UTC)
commit 31461013e57ab16cf4c54deb311680bff1cbf48a
Author: Heewa Barfchin <heewa b gmail com>
Date: Thu Jun 25 22:47:52 2020 -0400
Compare bytes/str correctly in both python 2 & 3
jhbuild/versioncontrol/git.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/jhbuild/versioncontrol/git.py b/jhbuild/versioncontrol/git.py
index 806a79ba..c2d21738 100644
--- a/jhbuild/versioncontrol/git.py
+++ b/jhbuild/versioncontrol/git.py
@@ -32,7 +32,7 @@ from jhbuild.utils.cmds import get_output, check_version
from jhbuild.versioncontrol import Repository, Branch, register_repo_type
from jhbuild.utils import inpath, _
from jhbuild.utils.sxml import sxml
-from jhbuild.utils import urlutils
+from jhbuild.utils import urlutils, udecode
from jhbuild.utils.urlutils import urlparse_mod
from jhbuild.utils.compat import iterkeys
@@ -365,7 +365,7 @@ class GitBranch(Branch):
proc = subprocess.Popen(cmd, stdout=subprocess.PIPE,
cwd=self.get_checkoutdir(),
env=get_git_extra_env())
- stdout = proc.communicate()[0]
+ stdout = udecode(proc.communicate()[0])
if not stdout.strip():
raise CommandError(_('Command %s returned no output') % cmd_desc)
for line in stdout.splitlines():
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]