From: Niko Mauno Date: Tue, 26 May 2026 05:59:59 +0000 (+0000) Subject: sbom-cve-check-common: Fatalize command failure X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=c56fed2c293dc384003e088154bc88c2d8aec472;p=thirdparty%2Fopenembedded%2Fopenembedded-core.git sbom-cve-check-common: Fatalize command failure Change the bb.error to bb.fatal in order to avoid marking the 'sbom_cve_check' task successful, even when it encounters an error, like: sbom-cve-check: error: [Errno 2] No such file or directory: '/build/layers/openembedded-core/build/tmp/deploy/images/qemuarm/.spdx.json' -NOTE: Tasks Summary: Attempted 5946 tasks of which 5283 didn't need to be rerun and all succeeded. +NOTE: Tasks Summary: Attempted 5945 tasks of which 5944 didn't need to be rerun and 1 failed. Signed-off-by: Niko Mauno Signed-off-by: Mathieu Dubois-Briand --- diff --git a/meta/classes/sbom-cve-check-common.bbclass b/meta/classes/sbom-cve-check-common.bbclass index 32c29a0ec2..1bd1af22b6 100644 --- a/meta/classes/sbom-cve-check-common.bbclass +++ b/meta/classes/sbom-cve-check-common.bbclass @@ -117,8 +117,7 @@ def run_sbom_cve_check(d, sbom_path, export_base_name, export_link_name=None): bb.note("Running: {}".format(" ".join(cmd_args))) bb.process.run(cmd_args, env=cmd_env) except bb.process.ExecutionError as e: - bb.error(f"sbom-cve-check failed: {e}") - return + bb.fatal(f"sbom-cve-check failed: {e}") show_warnings = bb.utils.to_boolean(d.getVar("SBOM_CVE_CHECK_SHOW_WARNINGS"))