-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpyproject.toml
More file actions
196 lines (174 loc) · 4.07 KB
/
Copy pathpyproject.toml
File metadata and controls
196 lines (174 loc) · 4.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
[build-system]
requires = [
"hatchling",
]
build-backend = "hatchling.build"
[project]
name = "http2py"
version = "0.1.34"
description = "Tools to create python binders to http web services."
readme = "README.md"
requires-python = ">=3.10"
license = "Apache-2.0"
keywords = [
"webservice",
"http",
"requests",
"API",
]
authors = [
{ name = "Otosense" },
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.12",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"glom",
"i2",
"ju",
"requests",
"cw>=0.1.1,<0.2",
"PyYAML",
"importlib_resources",
# TEMPORARY, not imported by http2py: ju/oas.py has an unconditional (and
# unused) `import dill` while not declaring dill, so a cold `pip install
# http2py` dies on `import ju`. Tracked upstream as i2mint/ju#6. Remove this
# line once a fixed ju is released -- tests/test_dependency_workarounds.py
# fails as soon as that happens, so it will not be forgotten.
"dill",
]
[project.urls]
Homepage = "https://github.com/i2mint/http2py"
Repository = "https://github.com/i2mint/http2py"
[project.scripts]
api-pkg-maker = "http2py.api_pkg_maker:main"
[project.optional-dependencies]
dev = [
"pytest>=7.0",
"pytest-cov>=4.0",
"ruff>=0.1.0",
# Not a runtime dependency of the package: `mk_api_pkg` shells out to
# `setup.py sdist`, so setuptools is needed to exercise it. A uv-created
# venv does not ship setuptools, so without this the end-to-end
# api_pkg_maker test would silently skip in CI.
"setuptools",
]
[tool.hatch.build.targets.wheel]
packages = [
"http2py",
]
[tool.ruff]
line-length = 88
target-version = "py310"
exclude = [
"**/*.ipynb",
".git",
".venv",
"build",
"dist",
"tests",
"examples",
"scrap",
]
[tool.ruff.lint]
select = [
"D100",
]
ignore = [
"D203",
"E501",
"B905",
]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.per-file-ignores]
"**/tests/*" = [
"D",
]
"**/examples/*" = [
"D",
]
"**/scrap/*" = [
"D",
]
[tool.pytest.ini_options]
minversion = "6.0"
testpaths = [
"http2py",
"tests",
]
norecursedirs = [
"build",
"dist",
".git",
".venv",
"*.egg-info",
]
doctest_optionflags = [
"NORMALIZE_WHITESPACE",
"ELLIPSIS",
]
[tool.wads.ci]
project_name = "http2py"
[tool.wads.ci.commands]
pre_test = []
test = []
post_test = []
lint = []
format = []
[tool.wads.ci.env]
required_envvars = []
test_envvars = []
extra_envvars = []
[tool.wads.ci.env.defaults]
[tool.wads.ci.quality.ruff]
enabled = true
[tool.wads.ci.quality.black]
enabled = false
[tool.wads.ci.quality.mypy]
enabled = false
[tool.wads.ci.testing]
python_versions = [
"3.10",
"3.12",
]
pytest_args = [
"-v",
"--tb=short",
]
coverage_enabled = true
coverage_threshold = 0
coverage_report_format = [
"term",
]
# `http2py/tests` stands up a real py2http web service, so it needs a test-only
# dependency that CI does not install. Excluding it from collection is what keeps
# `pytest --doctest-modules` from aborting the session on the import.
# (`http2py/api_pkg_maker.py` used to be excluded here too, because
# `setuptools.sandbox` no longer exists and the module was unimportable. It is
# fixed and collected again -- see issue #14.)
# This path is repeated in the repo-root conftest.py so that a bare `pytest`
# behaves like CI -- tests/test_ci_collection_contract.py keeps the two lists
# in agreement.
exclude_paths = [
"http2py/tests",
]
test_on_windows = false
[tool.wads.ci.metrics]
enabled = false
[tool.wads.ci.build]
sdist = true
wheel = true
[tool.wads.ci.publish]
enabled = true
# No docs builder: commit 43aef24 removed docs/ and docsrc/ from this repo, and
# the legacy CI's `epythet make . github` call is what turned the Publish job
# red. Nothing here to build.
[tool.wads.ci.docs]
enabled = false