-
-
Notifications
You must be signed in to change notification settings - Fork 11.1k
MAINT: Fix deprecated license specification in pyproject.toml
#29367
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
base: main
Are you sure you want to change the base?
Conversation
Now that PEP 639 is accepted, and meson-python suppopts it since version 0.18.0, the license specification should follow the PEP.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like the usage of the classifiers for this purpose is indeed deprecated in the PEP: https://peps.python.org/pep-0639/#deprecate-license-classifiers
This looks pretty decent to me--may want Ralf to quickly look it over, given familiarity with the metadata/PEP stuff.
"Cython>=3.0.6", # keep in sync with version check in meson.build | ||
] | ||
|
||
[project] | ||
name = "numpy" | ||
version = "2.4.0.dev0" | ||
# TODO: add `license-files` once PEP 639 is accepted (see meson-python#88) | ||
license = {file = "LICENSE.txt"} | ||
license = "BSD-3-Clause" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Out of curiosity/healthy skepticism, I naturally tried:
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -8,7 +8,7 @@ requires = [
[project]
name = "numpy"
version = "2.4.0.dev0"
-license = "BSD-3-Clause"
+license = "BSD-20-Clause"
and I do indeed see an error when I do an isolated local build:
meson-python: error: Unknown license: 'bsd-20-clause'
Thanks @koyuki7w. The main reason I hadn't done this yet is that it needs investigating if there's an issue with installing wheels with older versions of |
I had a branch here with more extensive changes already: main...rgommers:numpy:license-pep639 (not complete yet). |
This is the discussion about whether to include licenses of vendored code in the license expression is also probably relevant too: https://discuss.python.org/t/split-from-pep-639-expressing-project-vs-distribution-licenses-post-pep-639-mod-titled/90314 |
Now that PEP 639 is accepted, and meson-python suppopts it since version 0.18.0, the license specification should follow the PEP.