Repository navigation
feat(scan): skip failed builds with --dynamic-sbom-inference - #1820
Draft
Jeppe Fredsgaard Blaabjerg (jfblaa) wants to merge 1 commit into
Draft
Jeppe Fredsgaard Blaabjerg (jfblaa) wants to merge 1 commit into
Jeppe Fredsgaard Blaabjerg (jfblaa) wants to merge 1 commit into
Conversation
One failing build aborted --dynamic-sbom-inference for the whole repository. With --dynamic-sbom-inference-skip-failed-builds on scan create, scan reach and fix, or --skip-failed-builds on the manifest command, a build root that fails is left out with a warning, along with the build roots it holds back, and the other roots still produce Socket facts. What is left out is scanned from its manifest files as without --dynamic-sbom-inference. Telling what a failed build holds back needs Coana to report the projects its build tool read, so the option requires the first Coana that does.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
--dynamic-sbom-inference-skip-failed-builds(--skip-failed-buildsonsocket manifest dynamic-sbom-inference), so one failing build no longer aborts--dynamic-sbom-inferencefor a whole repository. A build root that fails is left out with a warning, along with the build roots it holds back, and every other root still produces Socket facts. What is left out is scanned from its manifest files as without--dynamic-sbom-inference, and reachability analysis leaves it out.Draft until Coana 15.15.10 is released and pinned: Coana reports which projects a failed build's tool read (coana-tech/coana-package-manager#2923), which needs a spar release that writes those records first.
What a failed build holds back
projectdirectory) still run.Behaviour
--reach-version.socket manifest dynamic-sbom-inferenceexits successfully when every failure was skipped; its JSON outcomes carryreasonandskipped, and text output marks the root(left out).socket.jsonsetting.Tests
generate-recursive-manifests.test.mts: what a failed reactor holds back for known, unknown and unreported modules and for a Coana failure, with and without the flag; a build of its own beneath a failure that reports nothing.run-manifest-facts.test.mts: Coana's failure blame and projects, and the minimum Coana version.run-dynamic-sbom-inference.test.mts,handle-manifest-dynamic-sbom-inference.test.mts: skipped failures warn and succeed; unskipped ones fail and name the flag.