Skip to content
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 exception issue and add regression tests #16

Merged
merged 2 commits into from
Nov 15, 2024
Merged

Conversation

PaulKMueller
Copy link
Collaborator

Motivation

Before this PR, issues could result from having, e.g., GPL-2.0-only WITH GCC-exception-2.0 whitelisted and checking a package with GPL-2.0-only.
conda-deny would not let the latter pass without checking for the exception in the whitelist.

Thanks @SimonLangerQC for pointing this out.

Changes

This PR adapts the checking to be more restrictive and adds a couple of regression tests.

@PaulKMueller PaulKMueller added the bug Something isn't working label Nov 15, 2024
@PaulKMueller PaulKMueller self-assigned this Nov 15, 2024
@PaulKMueller PaulKMueller marked this pull request as ready for review November 15, 2024 20:31
@PaulKMueller PaulKMueller merged commit 2aa62d4 into main Nov 15, 2024
14 checks passed
@PaulKMueller PaulKMueller deleted the exception-issue branch November 15, 2024 20:37
poppler = ">=24.8.0,<25"

[tool.conda-deny]
license-whitelist = "/Users/pkm/Projects/conda-deny/tests/test_end_to_end/test_exception_use_case/whitelist_with_exception.toml"
Copy link
Member

Choose a reason for hiding this comment

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

This shouldn't be absolute. Why did it pass CI?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Because just failure of the command execution is asserted for the integration test.
The unit tests should ensure the bug is fixed, but the integration test becomes useless.

I'll open a new PR with more stringent tests (for the other integration tests as well) that implements cleaner writing to stdout and stderr. That should also improve the tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants