Skip to content

Commit 2fcfaa9

Browse files
authored
Replace deprecated licence config in pyproject.toml (#268)
* Use an SPDX licence expression in pyproject.toml The project.license table and tool.setuptools.license-files are deprecated in setuptools, which warns about them on every build. Switch to the PEP 639 string form plus project.license-files, require setuptools>=77 for it, and drop the licence classifier, which setuptools rejects alongside a licence expression. * Add changelog fragment
1 parent fd9d468 commit 2fcfaa9

2 files changed

Lines changed: 4 additions & 6 deletions

File tree

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Replaced the deprecated licence configuration in ``pyproject.toml`` with an SPDX licence expression.

‎pyproject.toml‎

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[build-system]
22
# Defined by PEP 518
33
requires = [
4-
"setuptools>=64",
4+
"setuptools>=77",
55
"setuptools_scm[toml]>=7.0",
66
"wheel",
77
]
@@ -22,11 +22,11 @@ keywords = [
2222
"iris",
2323
"xarray",
2424
]
25-
license = {text = "BSD-3-Clause"}
25+
license = "BSD-3-Clause"
26+
license-files = ["LICENSE"]
2627
classifiers = [
2728
"Development Status :: 4 - Beta",
2829
"Intended Audience :: Science/Research",
29-
"License :: OSI Approved :: BSD License",
3030
"Natural Language :: English",
3131
"Operating System :: POSIX",
3232
"Operating System :: POSIX :: Linux",
@@ -56,9 +56,6 @@ Discussions = "https://github.com/SciTools/ncdata/discussions"
5656
Documentation = "https://ncdata.readthedocs.io"
5757
Issues = "https://github.com/SciTools/ncdata/issues"
5858

59-
[tool.setuptools]
60-
license-files = ["LICENSE"]
61-
6259
[tool.setuptools.dynamic]
6360
readme = {file = "README.md", content-type = "text/markdown"}
6461

0 commit comments

Comments
 (0)