Skip to content

Commit 621e497

Browse files
authored
pyproject: prep 4.0.0 (#219)
* pyproject: prep 4.0.0 Signed-off-by: William Woodruff <william@trailofbits.com> * remove 3.8, add 3.13 Signed-off-by: William Woodruff <william@trailofbits.com> * noxfile: remove 3.8, add 3.13 Signed-off-by: William Woodruff <william@trailofbits.com> --------- Signed-off-by: William Woodruff <william@trailofbits.com>
1 parent 8603eaf commit 621e497

File tree

3 files changed

+16
-19
lines changed

3 files changed

+16
-19
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
test:
1010
strategy:
1111
matrix:
12-
python: ['3.8', '3.9', '3.10', '3.11', '3.12']
12+
python: ['3.9', '3.10', '3.11', '3.12', '3.13']
1313
platform: [ubuntu-latest, macos-latest, windows-latest]
1414
runs-on: ${{ matrix.platform }}
1515
steps:

noxfile.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,10 @@
1010
#
1111
# and also to help confirm pull requests to this project.
1212

13-
import nox
1413
import os
1514

15+
import nox
16+
1617
nox.options.sessions = ["lint"]
1718

1819
# Define the minimal nox version required to run
@@ -39,7 +40,7 @@ def build_and_check_dists(session):
3940
session.run("python", "-m", "twine", "check", "dist/*")
4041

4142

42-
@nox.session(python=["3.8", "3.9", "3.10", "3.11", "3.12"])
43+
@nox.session(python=["3.9", "3.10", "3.11", "3.12", "3.13"])
4344
def tests(session):
4445
session.install("pytest")
4546
build_and_check_dists(session)

pyproject.toml

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99
# https://packaging.python.org/en/latest/tutorials/packaging-projects/#choosing-a-build-backend
1010
[build-system]
1111
# A list of packages that are needed to build your package:
12-
requires = ["setuptools"] # REQUIRED if [build-system] table is used
12+
requires = ["setuptools"] # REQUIRED if [build-system] table is used
1313
# The name of the Python object that frontends will use to perform the build:
14-
build-backend = "setuptools.build_meta" # If not defined, then legacy behavior can happen.
14+
build-backend = "setuptools.build_meta" # If not defined, then legacy behavior can happen.
1515

1616

1717
[project]
@@ -26,14 +26,14 @@ build-backend = "setuptools.build_meta" # If not defined, then legacy behavior
2626
# There are some restrictions on what makes a valid project name
2727
# specification here:
2828
# https://packaging.python.org/specifications/core-metadata/#name
29-
name = "sampleproject" # REQUIRED, is the only field that cannot be marked as dynamic.
29+
name = "sampleproject" # REQUIRED, is the only field that cannot be marked as dynamic.
3030

3131
# Versions should comply with PEP 440:
3232
# https://www.python.org/dev/peps/pep-0440/
3333
#
3434
# For a discussion on single-sourcing the version, see
3535
# https://packaging.python.org/guides/single-sourcing-package-version/
36-
version = "3.0.0" # REQUIRED, although can be dynamic
36+
version = "4.0.0" # REQUIRED, although can be dynamic
3737

3838
# This is a one-line description or tagline of what your project does. This
3939
# corresponds to the "Summary" metadata field:
@@ -54,12 +54,12 @@ readme = "README.md"
5454
# 'Programming Language' classifiers in this file, 'pip install' will check this
5555
# and refuse to install the project if the version does not match. See
5656
# https://packaging.python.org/guides/distributing-packages-using-setuptools/#python-requires
57-
requires-python = ">=3.8"
57+
requires-python = ">=3.9"
5858

5959
# This is either text indicating the license for the distribution, or a file
6060
# that contains the license.
6161
# https://packaging.python.org/en/latest/specifications/core-metadata/#license
62-
license = {file = "LICENSE.txt"}
62+
license = { file = "LICENSE.txt" }
6363

6464
# This field adds keywords for your project which will appear on the
6565
# project page. What does your project relate to?
@@ -72,15 +72,13 @@ keywords = ["sample", "setuptools", "development"]
7272
# This should be your name or the name of the organization who originally
7373
# authored the project, and a valid email address corresponding to the name
7474
# listed.
75-
authors = [
76-
{name = "A. Random Developer", email = "author@example.com" }
77-
]
75+
authors = [{ name = "A. Random Developer", email = "author@example.com" }]
7876

7977
# This should be your name or the names of the organization who currently
8078
# maintains the project, and a valid email address corresponding to the name
8179
# listed.
8280
maintainers = [
83-
{name = "A. Great Maintainer", email = "maintainer@example.com" }
81+
{ name = "A. Great Maintainer", email = "maintainer@example.com" },
8482
]
8583

8684
# Classifiers help users find your project by categorizing it.
@@ -104,11 +102,11 @@ classifiers = [
104102
# that you indicate you support Python 3. These classifiers are *not*
105103
# checked by "pip install". See instead "requires-python" key in this file.
106104
"Programming Language :: Python :: 3",
107-
"Programming Language :: Python :: 3.8",
108105
"Programming Language :: Python :: 3.9",
109106
"Programming Language :: Python :: 3.10",
110107
"Programming Language :: Python :: 3.11",
111108
"Programming Language :: Python :: 3.12",
109+
"Programming Language :: Python :: 3.13",
112110
"Programming Language :: Python :: 3 :: Only",
113111
]
114112

@@ -118,17 +116,15 @@ classifiers = [
118116
#
119117
# For an analysis of this field vs pip's requirements files see:
120118
# https://packaging.python.org/discussions/install-requires-vs-requirements/
121-
dependencies = [
122-
"peppercorn"
123-
]
119+
dependencies = ["peppercorn"]
124120

125121
# List additional groups of dependencies here (e.g. development
126122
# dependencies). Users will be able to install these using the "extras"
127123
# syntax, for example:
128124
#
129125
# $ pip install sampleproject[dev]
130126
#
131-
# Optional dependencies the project provides. These are commonly
127+
# Optional dependencies the project provides. These are commonly
132128
# referred to as "extras". For a more extensive definition see:
133129
# https://packaging.python.org/en/latest/specifications/dependency-specifiers/#extras
134130
[project.optional-dependencies]
@@ -163,4 +159,4 @@ sample = "sample:main"
163159
[tool.setuptools]
164160
# If there are data files included in your packages that need to be
165161
# installed, specify them here.
166-
package-data = {"sample" = ["*.dat"]}
162+
package-data = { "sample" = ["*.dat"] }

0 commit comments

Comments
 (0)