Skip to content

Add pyproject-fmt pre-commit hook#101

Open
graingert wants to merge 2 commits intopytest-dev:mainfrom
graingert:pyproject-fmt
Open

Add pyproject-fmt pre-commit hook#101
graingert wants to merge 2 commits intopytest-dev:mainfrom
graingert:pyproject-fmt

Conversation

@graingert
Copy link
Copy Markdown
Member

Reformats pyproject.toml: sorts keys, normalises array style, flattens sub-tables, removes redundant classifiers (Programming Language :: Python :: 3 is implied by 3 :: Only, 3.15 is not yet a valid PyPI classifier).

@graingert
Copy link
Copy Markdown
Member Author

Whl diff:

diff -ru main/dist-info/METADATA pyproject-fmt/dist-info/METADATA
--- main/dist-info/METADATA	2026-04-06 16:20:06.000000000 +0000
+++ pyproject-fmt/dist-info/METADATA	2026-04-06 16:20:14.000000000 +0000
@@ -10,7 +10,6 @@
 Classifier: Intended Audience :: Developers
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python
-Classifier: Programming Language :: Python :: 3
 Classifier: Programming Language :: Python :: 3 :: Only
 Classifier: Programming Language :: Python :: 3.9
 Classifier: Programming Language :: Python :: 3.10
@@ -18,7 +17,6 @@
 Classifier: Programming Language :: Python :: 3.12
 Classifier: Programming Language :: Python :: 3.13
 Classifier: Programming Language :: Python :: 3.14
-Classifier: Programming Language :: Python :: 3.15
 Classifier: Topic :: Software Development
 Classifier: Topic :: Utilities
 Requires-Python: >=3.9
diff -ru main/dist-info/RECORD pyproject-fmt/dist-info/RECORD
--- main/dist-info/RECORD	2026-04-06 16:20:06.000000000 +0000
+++ pyproject-fmt/dist-info/RECORD	2026-04-06 16:20:14.000000000 +0000
@@ -6,7 +6,7 @@
 unittest2pytest/fixes/fix_self_assert.py,sha256=3orCNTVSdOSYaiXJjYU6vsZ9jmRYqCLhqzsCRE40wZ0,16418
 unittest2pytest-0.6.dev0.dist-info/licenses/AUTHORS.txt,sha256=b8CwrXUsgKEAa2JBX5cttbUsb68ZvdcQ1CuL_JSE09A,941
 unittest2pytest-0.6.dev0.dist-info/licenses/COPYING-GPLv3.txt,sha256=jOtLnuWt7d5Hsx6XXB2QxzrSe2sWWh3NgMfFRetluQM,35147
-unittest2pytest-0.6.dev0.dist-info/METADATA,sha256=Y2RFORa8jXn3q4uPDGD1BLlQwxqEJnqdrBN6flay9i4,5708
+unittest2pytest-0.6.dev0.dist-info/METADATA,sha256=YW3un2zdRXtynFsWYV9P-yzTeyfOpLacNZqUKZGEfNs,5609
 unittest2pytest-0.6.dev0.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
 unittest2pytest-0.6.dev0.dist-info/entry_points.txt,sha256=EP8-0SMaIaC4fkmVUCG1cRhwOJZffcGJ6yGUurH9qo0,66
 unittest2pytest-0.6.dev0.dist-info/top_level.txt,sha256=sKQCbFtrGyQMbYJST27LYZ3Rblil8LPZr25xSuCCbjk,16

Following pytest's pre-commit config. Uses pytest-dev/pyproject-fmt
with tox>=4.9 for computing max supported Python version.

Adds [tool.pyproject-fmt] max_supported_python = "3.15" to preserve
the 3.15 classifier. Removes redundant 'Programming Language ::
Python :: 3' classifier (implied by '3 :: Only').
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