mirror of
https://git.yoctoproject.org/poky
synced 2026-03-19 05:39:39 +01:00
sanity: check_perl_modules bug fix
Fix Python3 TypeError error in check_perl_modules:
Executing bitbake, the following error message will be throwed:
File ".../poky/meta/classes/sanity.bbclass", line
979, in check_sanity_eventhandler
check_sanity(sanity_data)
File ".../poky/meta/classes/sanity.bbclass", line
943, in check_sanity
check_sanity_version_change(status, sanity_data)
File ".../poky/meta/classes/sanity.bbclass", line
637, in check_sanity_version_change
status.addresult(check_perl_modules(d))
File ".../poky/meta/classes/sanity.bbclass", line
563, in check_perl_modules
errresult += e.output
TypeError: must be str, not bytes
So here, transfer e.output from bytes to str.
(From OE-Core rev: 2c6fff3fe315357d65d082679856615afc367d90)
Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
9f7092416c
commit
5ad7d90ee6
@@ -560,7 +560,7 @@ def check_perl_modules(sanity_data):
|
||||
try:
|
||||
subprocess.check_output(["perl", "-e", "use %s" % m])
|
||||
except subprocess.CalledProcessError as e:
|
||||
errresult += e.output
|
||||
errresult += bytes.decode(e.output)
|
||||
ret += "%s " % m
|
||||
if ret:
|
||||
return "Required perl module(s) not found: %s\n\n%s\n" % (ret, errresult)
|
||||
|
||||
Reference in New Issue
Block a user