Skip to content

Migrate license metadata to SPDX expression#685

Open
gilbsgilbs wants to merge 2 commits intowhipper-team:developfrom
gilbsgilbs:trove-classifier
Open

Migrate license metadata to SPDX expression#685
gilbsgilbs wants to merge 2 commits intowhipper-team:developfrom
gilbsgilbs:trove-classifier

Conversation

@gilbsgilbs
Copy link
Copy Markdown

This project was using an incorrect trove classifier for GPLv3 (License :: OSI Approved :: GNU General Public License v3 instead of License :: OSI Approved :: GNU General Public License v3 (GPLv3))¹, which was leading to build failures with non-isolated builds. We could update just this classifier, however license trove classifiers are now deprecated, and the modern way of declaring licenses is though SPDX expressions² ³.

  • Replace the deprecated license = {file = "LICENSE"} with a plain SPDX expression
  • Add an explicit license-files entry to make sure it's included in builds
  • Drop the now-redundant license trove classifier

[1] https://pypi.org/classifiers/#:~:text=GPLv3
[2] https://packaging.python.org/en/latest/guides/writing-pyproject-toml/#license-and-license-files
[3] https://peps.python.org/pep-0639/

Copy link
Copy Markdown

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

💖 Thanks for opening your first pull request here! 💖

"License :: OSI Approved :: GNU General Public License v3" is not a
valid trove classifier; the correct value per the trove-classifiers spec
is "License :: OSI Approved :: GNU General Public License v3 (GPLv3)".

This causes build failures for distribution package maintainers who use
`python -m build --no-isolation`, which exposes the build to a
system-installed validate-pyproject that enforces the classifier spec.
Isolated builds are unaffected.

Signed-off-by: Gilbert Gilb's <gilbsgilbert@gmail.com>
Replace the deprecated `license = {file = "LICENSE"}` TOML table with a
plain SPDX expression (`license = "GPL-3.0-only"`) and an explicit
`license-files` entry, and drop the now-redundant license trove
classifier.

Fixes deprecation warnings from setuptools >= 77.

Signed-off-by: Gilbert Gilb's <gilbsgilbert@gmail.com>
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.

1 participant