Skip to content

fix: update exit code#4715

Closed
ffontaine wants to merge 2 commits intoossf:mainfrom
ffontaine:fix-cli-exit-code
Closed

fix: update exit code#4715
ffontaine wants to merge 2 commits intoossf:mainfrom
ffontaine:fix-cli-exit-code

Conversation

@ffontaine
Copy link
Collaborator

Do not return 1 if CVEs are found as under Linux, it means that the program exited with a "General Error"

Do not return 1 if CVEs are found as under Linux, it means that the
program exited with a "General Error"

Signed-off-by: Fabrice Fontaine <[email protected]>
Copy link
Collaborator

@terriko terriko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we should change this: I know a number of users who rely on the exit code failure to tell if their automation/CI systems have detected new CVEs and act accordingly.

We could maybe consider using a different error code (although it does have to be a positive number because of undefined behaviour on windows), but we absolutely do need to return something other than 0 here or we're going to break a lot of stuff. This would have to be a 4.0 level breaking change, I think.

@ffontaine ffontaine closed this Mar 7, 2025
@ffontaine ffontaine deleted the fix-cli-exit-code branch March 7, 2025 13:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants