Repository navigation
chore(sync): merge main into new-resolver-config - #1454
Merged
Conversation
`_parse_spdx()` skipped validation only when the whole expression started with `LicenseRef-`. A valid PEP 639 expression such as `MIT OR LicenseRef-Proprietary` was rejected, while `LicenseRef-Foo OR Apache 2` and malformed ids like `LicenseRef-a_b` were accepted. It now parses without validation and rejects every unknown key that is not a well-formed `LicenseRef-` id, raising the same `ExpressionError` as before. This is needed to populate SBOM license fields (python-wheel-build#1378). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Martin Prpič <mprpic@redhat.com>
Validate with `packaging.licenses.canonicalize_license_expression()` so `_parse_spdx()` follows PEP 639 exactly, and use license-expression only to build the expression object. `Apache-2.0 WITH LicenseRef-x` is now rejected and `licenseref-foo` accepted, matching `packaging`. The exception type stays `ExpressionError`; its message now comes from `packaging`. The invalid-expression cases move to their own test that checks which key was rejected, and new cases cover an exception next to a `LicenseRef` and an unknown `WITH` exception. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Martin Prpič <mprpic@redhat.com>
…-licenseref fix(pkgmetadata): accept LicenseRef anywhere in SPDX expressions
Bring in the SPDX `LicenseRef` fix from python-wheel-build#1452 so python-wheel-build#1414 is up to date with main before merging. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Lalatendu Mohanty <lmohanty@redhat.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
smoparth
approved these changes
Nov 4, 2026
Contributor
|
This pull request does not currently match the merge queue conditions, so it cannot be queued from here. The box comes back if it matches again. |
rd4398
approved these changes
Nov 4, 2026
LalatenduMohanty
merged commit Nov 4, 2026
2d34b1a
into
python-wheel-build:new-resolver-config
36 checks passed
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.
Merges
mainintonew-resolver-configso #1414 is up to date before merging.Brings in one change: the SPDX
LicenseReffix from #1452. The merge had no conflicts, andtests/test_pkgmetadata.pypasses.Please merge this with a merge commit (not squash), so the branch stays in sync with
main.🤖 Generated with Claude Code