-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add supplier/license info for cargo and pip #479
base: main
Are you sure you want to change the base?
Conversation
@@ -78,6 +78,7 @@ public abstract class ComponentDetectionBaseWalker | |||
// Enable SPDX22 and ConanLock detector which is disabled by default. | |||
cliArgumentBuilder.AddDetectorArg("SPDX22SBOM", "EnableIfDefaultOff"); | |||
cliArgumentBuilder.AddDetectorArg("ConanLock", "EnableIfDefaultOff"); | |||
cliArgumentBuilder.AddDetectorArg("RustCli", "EnableIfDefaultOff"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RustCli detector is not enabled by default. Must be enabled manually here.
@@ -29,6 +29,8 @@ protected override IEnumerable<ScannedComponent> FilterScannedComponents(ScanRes | |||
return result | |||
.ComponentsFound | |||
.Where(component => !(component.Component is SpdxComponent)) // We exclude detected SBOMs from packages section and reference them as an ExternalReference | |||
.GroupBy(component => component.Component.Id) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now that both the RustCrateDetector and the RustCli detector are both running we may have duplicates. In this scenario we always want to take the one that came from the RustCli as this one contains Author and Supplier information.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #479 +/- ##
==========================================
+ Coverage 59.82% 59.85% +0.03%
==========================================
Files 268 268
Lines 8249 8256 +7
Branches 972 973 +1
==========================================
+ Hits 4935 4942 +7
Misses 2886 2886
Partials 428 428 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be nice to add some test coverage around these changes, but otherwise looks good.
Requires #476 to be merged for it's changes in ServiceCollectionExtensions as well as v4.0.12 of component-detection to be released
Edit: all requirements have been met.