-
Notifications
You must be signed in to change notification settings - Fork 318
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
fix(helper-cli): Fix broken reading of scan results by identifier #8613
Conversation
739e12c
to
9944229
Compare
9944229
to
eb8afcb
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #8613 +/- ##
=========================================
Coverage 67.97% 67.97%
Complexity 1005 1005
=========================================
Files 244 244
Lines 7844 7844
Branches 876 876
=========================================
Hits 5332 5332
Misses 2129 2129
Partials 383 383
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Commit message: Typo in "provnenance". |
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.
Tested this PR on several of the projects I currently doing license clearance for .. it working again as expected.
The refactoring done in [1] does not just merge functions, but in addition changes the behavior of the `read()` function to filter the result by the provenance of the given package. So, [1] obviously broke the reading of scan results in `helper-cli`'s `CreateCommand`, see also [2][3]. A better way to fix this might be to migrate the command to use a scan results by provenance storage together with a package / nested provenance storage. As this is a bigger effort, fix the regression from [1] for now in a rather minimal invasive way, which just bypasses the filtering by provenance. [1]: 70b1b86 [2]: https://github.com/oss-review-toolkit/ort/blob/8ed8e2bff913f1d3aafecfb6eb746614f01dfafc/helper-cli/src/main/kotlin/commands/packageconfig/CreateCommand.kt#L123 [3]: https://github.com/oss-review-toolkit/ort/blob/8ed8e2bff913f1d3aafecfb6eb746614f01dfafc/scanner/src/main/kotlin/storages/PackageBasedFileStorage.kt#L75 Signed-off-by: Frank Viernau <[email protected]>
eb8afcb
to
c13ff80
Compare
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.
So, [1] obviously broke the reading of scan results in
helper-cli
'sCreateCommand
Having tests for the helper-cli would certainly help preventing such issues in future.
See commit message.