Skip to content

Commit 63d01da

Browse files
committed
modernize everything
1 parent 5f129a0 commit 63d01da

34 files changed

+126
-95
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88

99
jobs:
1010
tox:
11-
runs-on: ubuntu-20.04 # bump to -latest or -22.04 once we drop py36
11+
runs-on: ubuntu-latest
1212
strategy:
1313
max-parallel: 5
1414
matrix:

MANIFEST.in

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
graft src/h2
22
graft docs
3-
graft test
3+
graft tests
44
graft visualizer
55
graft examples
6+
67
prune docs/build
8+
79
recursive-include examples *.py *.crt *.key *.pem *.csr
10+
811
include README.rst LICENSE CHANGELOG.rst tox.ini
12+
913
global-exclude *.pyc *.pyo *.swo *.swp *.map *.yml *.DS_Store

pyproject.toml

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
# https://packaging.python.org/en/latest/guides/writing-pyproject-toml/
2+
# https://packaging.python.org/en/latest/specifications/pyproject-toml/
3+
4+
[build-system]
5+
requires = ["setuptools"]
6+
build-backend = "setuptools.build_meta"
7+
8+
[project]
9+
name = "h2"
10+
description = "Pure-Python HTTP/2 protocol implementation"
11+
readme = { file = "README.rst", content-type = "text/x-rst" }
12+
license = { file = "LICENSE" }
13+
14+
authors = [
15+
{ name = "Cory Benfield", email = "[email protected]" }
16+
]
17+
maintainers = [
18+
{ name = "Thomas Kriechbaumer", email = "[email protected]" },
19+
]
20+
21+
requires-python = ">=3.9"
22+
dependencies = [
23+
"hyperframe>=6.0,<7",
24+
"hpack>=4.0,<5",
25+
]
26+
dynamic = ["version"]
27+
28+
# For a list of valid classifiers, see https://pypi.org/classifiers/
29+
classifiers = [
30+
"Development Status :: 5 - Production/Stable",
31+
"Intended Audience :: Developers",
32+
"License :: OSI Approved :: MIT License",
33+
"Programming Language :: Python",
34+
"Programming Language :: Python :: 3 :: Only",
35+
"Programming Language :: Python :: 3",
36+
"Programming Language :: Python :: 3.9",
37+
"Programming Language :: Python :: 3.10",
38+
"Programming Language :: Python :: 3.11",
39+
"Programming Language :: Python :: 3.12",
40+
"Programming Language :: Python :: 3.13",
41+
"Programming Language :: Python :: Implementation :: CPython",
42+
"Programming Language :: Python :: Implementation :: PyPy",
43+
]
44+
45+
[project.urls]
46+
"Homepage" = "https://github.com/python-hyper/h2/"
47+
"Bug Reports" = "https://github.com/python-hyper/h2/issues"
48+
"Source" = "https://github.com/python-hyper/h2/"
49+
"Documentation" = "https://python-hyper.org/"
50+
51+
[dependency-groups]
52+
testing = [
53+
"pytest>=8.3.3,<9",
54+
"pytest-cov>=6.0.0,<7",
55+
"pytest-xdist>=3.6.1,<4",
56+
"hypothesis>=6.119.4,<7",
57+
]
58+
59+
linting = [
60+
"ruff>=0.8.0,<1",
61+
"mypy>=1.13.0,<2",
62+
]
63+
64+
packaging = [
65+
"check-manifest==0.50",
66+
"readme-renderer==44.0",
67+
"build>=1.2.2,<2",
68+
"twine>=5.1.1,<6",
69+
"wheel>=0.45.0,<1",
70+
]
71+
72+
docs = [
73+
"sphinx>=7.4.7,<9",
74+
]
75+
76+
[tool.setuptools.packages.find]
77+
where = [ "src" ]
78+
79+
[tool.setuptools.package-data]
80+
h2 = [ "py.typed" ]
81+
82+
[tool.setuptools.dynamic]
83+
version = { attr = "h2.__version__" }
84+
85+
[tool.ruff]
86+
line-length = 140
87+
target-version = "py39"
88+
89+
[tool.pytest.ini_options]
90+
testpaths = [ "tests" ]
91+
92+
[tool.coverage.run]
93+
branch = true
94+
source = [ "h2" ]
95+
96+
[tool.coverage.report]
97+
fail_under = 100
98+
show_missing = true
99+
exclude_lines = [
100+
"pragma: no cover",
101+
"raise NotImplementedError()",
102+
'assert False, "Should not be reachable"',
103+
# .*:.* # Python \d.*
104+
# .*:.* # Platform-specific:
105+
]
106+
107+
[tool.coverage.paths]
108+
source = [
109+
"src/",
110+
".tox/**/site-packages/",
111+
]

setup.cfg

Lines changed: 0 additions & 24 deletions
This file was deleted.

setup.py

Lines changed: 0 additions & 54 deletions
This file was deleted.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)