diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-03-25 10:33:21 +0000 |
---|---|---|
committer | Armin Kuster <akuster808@gmail.com> | 2019-05-17 21:18:44 -0700 |
commit | 5685a349eb471f4c8c9dcc2dc3b34f20369920bb (patch) | |
tree | 7303cd9be757269b89443fb67770867599f3d027 | |
parent | 6351f52609af51055786f7b3b24aee722b4dcea4 (diff) | |
download | openembedded-core-5685a349eb471f4c8c9dcc2dc3b34f20369920bb.tar.gz openembedded-core-5685a349eb471f4c8c9dcc2dc3b34f20369920bb.tar.bz2 openembedded-core-5685a349eb471f4c8c9dcc2dc3b34f20369920bb.zip |
oeqa/qemurunner: Dont mix binary and non-binary strings
self.msg is a str(), bootlog is b'' so this code clearly doesn't work. Add
in a decode since its being used as a string.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r-- | meta/lib/oeqa/utils/qemurunner.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/meta/lib/oeqa/utils/qemurunner.py b/meta/lib/oeqa/utils/qemurunner.py index cc95dc2990..5d1d0cceca 100644 --- a/meta/lib/oeqa/utils/qemurunner.py +++ b/meta/lib/oeqa/utils/qemurunner.py @@ -320,6 +320,7 @@ class QemuRunner: self.logger.debug("Target didn't reach login banner in %d seconds (%s)" % (self.boottime, time.strftime("%D %H:%M:%S"))) tail = lambda l: "\n".join(l.splitlines()[-25:]) + bootlog = boolog.decode("utf-8") # in case bootlog is empty, use tail qemu log store at self.msg lines = tail(bootlog if bootlog else self.msg) self.logger.debug("Last 25 lines of text:\n%s" % lines) |