From: Alexander Kanavin Date: Fri, 1 Nov 2024 09:15:53 +0000 (+0100) Subject: oeqa/runCmd: print stderr when that is a separate stream X-Git-Tag: uninative-4.7~1017 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=72c747b37ccdd486ddae06e3d0a99fb2b93643ba;p=thirdparty%2Fopenembedded%2Fopenembedded-core.git oeqa/runCmd: print stderr when that is a separate stream runCmd by default merges stderr into stdout, and only needs to print stdout when errors occur. When stderr is requested as a separate stream, and an error occurs, stderr is discarded, obscuring useful error messages. This changes the output to include both streams. Signed-off-by: Alexander Kanavin Signed-off-by: Richard Purdie --- diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py index ca22d69f291..2a47f90e327 100644 --- a/meta/lib/oeqa/utils/commands.py +++ b/meta/lib/oeqa/utils/commands.py @@ -203,6 +203,8 @@ def runCmd(command, ignore_status=False, timeout=None, assert_error=True, sync=T if result.status and not ignore_status: exc_output = result.output + if result.error: + exc_output = exc_output + result.error if limit_exc_output > 0: split = result.output.splitlines() if len(split) > limit_exc_output: