Skip to content

Improve license parsing error messages #339

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

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft

Improve license parsing error messages #339

wants to merge 1 commit into from

Conversation

goneall
Copy link
Member

@goneall goneall commented Jul 3, 2025

Fixes #338

Dependes on updates to the SPDX Models versions 2 and 3 which add a new class "InvalidLicenseExpression" which is used to produce the errors.

This changes the behavior of the license parser from throwing an exception to returning an InvalidLicenseExpression where the verify routine will return the error message.

Fixes #338

Dependes on updates to the SPDX Models versions 2 and 3 which add
a new class "InvalidLicenseExpression" which is used to produce the
errors.

This changes the behavior of the license parser from throwing an
exception to returning an InvalidLicenseExpression where the verify
routine will return the error message.
goneall added a commit to spdx/spdx-java-model-2_X that referenced this pull request Jul 3, 2025
Supports improvements to the license parsing error handling.

See spdx/Spdx-Java-Library#339 for reference.
goneall added a commit to spdx/spdx-model-to-java that referenced this pull request Jul 3, 2025
Supports improvements to the license parsing error handling.

See spdx/Spdx-Java-Library#339 for reference.
goneall added a commit to spdx/spdx-java-model-2_X that referenced this pull request Jul 3, 2025
Supports improvements to the license parsing error handling.

See spdx/Spdx-Java-Library#339 for reference.
@bact bact added enhancement New feature or request error-handling How errors are caught, processed, and communicated and removed enhancement New feature or request labels Jul 4, 2025
goneall added a commit to spdx/spdx-model-to-java that referenced this pull request Jul 6, 2025
Supports improvements to the license parsing error handling.

See spdx/Spdx-Java-Library#339 for reference.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
error-handling How errors are caught, processed, and communicated
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve error handling for invalid license expressions
2 participants