diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-12-01 14:05:16 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-12-06 10:19:10 +0000 |
commit | 2696e69af0b32e03692d8644cc01b28dcf221aa1 (patch) | |
tree | 99d3527c3e810d6b993a348ff764bdec64bbe2fb /meta/lib/oeqa/selftest | |
parent | eee30d799ff892443d21de4128e7d643215b0ac1 (diff) | |
download | openembedded-core-2696e69af0b32e03692d8644cc01b28dcf221aa1.tar.gz openembedded-core-2696e69af0b32e03692d8644cc01b28dcf221aa1.tar.bz2 openembedded-core-2696e69af0b32e03692d8644cc01b28dcf221aa1.zip |
lib/oe/utils: Improve multiprocess_lauch exception handling
We've seen a cryptic:
"ERROR: Fatal errors occurred in subprocesses, tracebacks printed above"
message from oe-selftest with no other traceback information. Improve the
traceback logging to try and give a better indication of any errors that is
ocurring.
(From OE-Core rev: 521dd3d00979a27b6932e58d5497de68abac26e1)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/selftest')
-rw-r--r-- | meta/lib/oeqa/selftest/cases/oelib/utils.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/cases/oelib/utils.py b/meta/lib/oeqa/selftest/cases/oelib/utils.py index 275aeda74e..789c6f78d2 100644 --- a/meta/lib/oeqa/selftest/cases/oelib/utils.py +++ b/meta/lib/oeqa/selftest/cases/oelib/utils.py @@ -66,6 +66,9 @@ class TestMultiprocessLaunch(TestCase): def dummyerror(msg): print("ERROR: %s" % msg) + def dummyfatal(msg): + print("ERROR: %s" % msg) + raise bb.BBHandledException() @contextmanager def captured_output(): @@ -79,6 +82,7 @@ class TestMultiprocessLaunch(TestCase): d = bb.data_smart.DataSmart() bb.error = dummyerror + bb.fatal = dummyfatal # Assert the function returns the right results result = multiprocess_launch(testfunction, ["3", "4", "5", "6"], d, extraargs=(d,)) |