summaryrefslogtreecommitdiffstats
path: root/scripts/oe-selftest
diff options
context:
space:
mode:
authorEd Bartosh <ed.bartosh@linux.intel.com>2016-06-02 13:13:00 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-06-02 11:49:50 +0100
commitae4d36375683b6cfd48af25bfca70b2e77f7ade5 (patch)
tree578f7d07c097dd604d3d0bc682b2f2f798f43e72 /scripts/oe-selftest
parentbf1b411eb1cd2cc960325d5fdb0cb4f4f7b1e40e (diff)
downloadopenembedded-core-ae4d36375683b6cfd48af25bfca70b2e77f7ade5.tar.gz
scripts: python3: decode subprocess output
stdeout and stderr content returned by subprocess API has different types in Python 3(bytes) and Python 2(string). Decoding it to 'utf-8' makes it unicode on both pythons. Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/oe-selftest')
-rwxr-xr-xscripts/oe-selftest2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/oe-selftest b/scripts/oe-selftest
index b1ecf7f322..df76f94f7a 100755
--- a/scripts/oe-selftest
+++ b/scripts/oe-selftest
@@ -371,7 +371,7 @@ def coverage_setup(coverage_source, coverage_include, coverage_omit):
import subprocess
builddir = os.environ.get("BUILDDIR")
pokydir = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
- curcommit= subprocess.check_output(["git", "--git-dir", os.path.join(pokydir, ".git"), "rev-parse", "HEAD"])
+ curcommit= subprocess.check_output(["git", "--git-dir", os.path.join(pokydir, ".git"), "rev-parse", "HEAD"]).decode('utf-8')
coveragerc = "%s/.coveragerc" % builddir
data_file = "%s/.coverage." % builddir
data_file += datetime.datetime.now().strftime('%Y%m%dT%H%M%S')