Skip to content

Commit 9932218

Browse files
committed
Use standardized [project] table in pyproject.toml
This allows us to swap the build backend more easily in RHEL, where we don't have poetry-code. This requires poetry-core >= 2 because older poetry did not support this. Also, replace the value of the license text with a SPDX identifier as documented in https://python-poetry.org/docs/pyproject/#license Otherwise, poetry-core injects a `Other/Proprietary License` classifier. (Note that poetry-core does not yet support PEP 639 fully). This change creates s slight change in the metadata, comments inline. --- old/qrcode-8.2-py3-none-any/qrcode-8.2.dist-info/METADATA +++ new/qrcode-8.2-py3-none-any/qrcode-8.2.dist-info/METADATA @@ -2,16 +2,15 @@ Name: qrcode Version: 8.2 Summary: QR Code image generator -License: BSD +License: BSD-3-Clause This was intentional. Keywords: qr,denso-wave,IEC18004 Author: Lincoln Loop Author-email: [email protected] -Requires-Python: >=3.9,<4.0 +Requires-Python: ~=3.9 This is identical in reality. Classifier: Development Status :: 5 - Production/Stable -Classifier: Intended Audience :: Developers This only changes order :/ Classifier: License :: OSI Approved :: BSD License -Classifier: License :: Other/Proprietary License This is intentional. Classifier: Operating System :: OS Independent +Classifier: Intended Audience :: Developers See above, order only. Classifier: Programming Language :: Python Classifier: Programming Language :: Python :: 3 Classifier: Programming Language :: Python :: 3.9 @@ -26,8 +25,10 @@ Provides-Extra: pil Provides-Extra: png Requires-Dist: colorama ; sys_platform == "win32" -Requires-Dist: pillow (>=9.1.0) ; extra == "pil" or extra == "all" -Requires-Dist: pypng ; extra == "png" or extra == "all" +Requires-Dist: pillow (>=9.1.0) ; extra == "all" +Requires-Dist: pillow (>=9.1.0) ; extra == "pil" +Requires-Dist: pypng ; extra == "all" +Requires-Dist: pypng ; extra == "png" This is identical. Project-URL: Homepage, https://github.com/lincolnloop/python-qrcode Description-Content-Type: text/x-rst
1 parent 3704f57 commit 9932218

File tree

1 file changed

+26
-22
lines changed

1 file changed

+26
-22
lines changed

pyproject.toml

Lines changed: 26 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
[build-system]
2-
requires = ["poetry-core"]
2+
requires = ["poetry-core>=2"]
33
build-backend = "poetry.core.masonry.api"
44

5-
[tool.poetry]
5+
[project]
66
name = "qrcode"
77
version = "8.2"
8-
packages = [{include = "qrcode"}]
98
description = "QR Code image generator"
10-
authors = ["Lincoln Loop <[email protected]>"]
11-
license = "BSD"
12-
readme = ["README.rst", "CHANGES.rst"]
13-
homepage = "https://github.com/lincolnloop/python-qrcode"
9+
authors = [
10+
{ name = "Lincoln Loop", email = "[email protected]" },
11+
]
12+
license = { text = "BSD-3-Clause" }
13+
dynamic = [ "readme" ]
1414
keywords = ["qr", "denso-wave", "IEC18004"]
1515
classifiers = [
1616
"Development Status :: 5 - Production/Stable",
@@ -28,6 +28,25 @@ classifiers = [
2828
"Topic :: Multimedia :: Graphics",
2929
"Topic :: Software Development :: Libraries :: Python Modules",
3030
]
31+
requires-python = "~=3.9"
32+
dependencies = [
33+
"colorama; sys_platform == 'win32'",
34+
]
35+
36+
[project.optional-dependencies]
37+
pil = ["pillow >=9.1.0"]
38+
png = ["pypng"]
39+
all = ["pypng", "pillow >=9.1.0"]
40+
41+
[project.urls]
42+
homepage = "https://github.com/lincolnloop/python-qrcode"
43+
44+
[project.scripts]
45+
qr = "qrcode.console_scripts:main"
46+
47+
[tool.poetry]
48+
packages = [{include = "qrcode"}]
49+
readme = ["README.rst", "CHANGES.rst"]
3150

3251
# There is no support for data files yet.
3352
# https://github.com/python-poetry/poetry/issues/9519
@@ -36,21 +55,6 @@ classifiers = [
3655
# { destination = "share/man/man1", from = [ "doc/qr.1" ] },
3756
# ]
3857

39-
[tool.poetry.scripts]
40-
qr = 'qrcode.console_scripts:main'
41-
42-
43-
[tool.poetry.dependencies]
44-
python = "^3.9"
45-
colorama = {version = "*", platform = "win32"}
46-
pypng = {version = "*", optional = true}
47-
pillow = {version = ">=9.1.0", optional = true}
48-
49-
[tool.poetry.extras]
50-
pil = ["pillow"]
51-
png = ["pypng"]
52-
all = ["pypng","pillow"]
53-
5458
[tool.poetry.group.dev.dependencies]
5559
pytest = {version = "*"}
5660
pytest-cov = {version = "*"}

0 commit comments

Comments
 (0)