-
Notifications
You must be signed in to change notification settings - Fork 124
/
pyproject.toml
195 lines (173 loc) · 4.78 KB
/
pyproject.toml
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
[build-system]
requires = ["flit-core >= 3.8"]
build-backend = "flit_core.buildapi"
[project]
name = "build"
description = "A simple, correct Python build frontend"
readme = "README.md"
requires-python = ">= 3.8"
license.file = "LICENSE"
authors = [
{ name = "Filipe Laíns", email = "[email protected]" },
{ name = "Bernát Gábor", email = "[email protected]" },
{ name = "layday", email = "[email protected]" },
{ name = "Henry Schreiner", email = "[email protected]" },
]
classifiers = [
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
]
urls.changelog = "https://build.pypa.io/en/stable/changelog.html"
urls.homepage = "https://build.pypa.io"
urls.issues = "https://github.com/pypa/build/issues"
urls.source = "https://github.com/pypa/build"
# Version read from __version__ field in __init__.py by Flit
dynamic = ["version"]
dependencies = [
"packaging >= 19.1",
"pyproject_hooks",
# not actually a runtime dependency, only supplied as there is not "recommended dependency" support
'colorama; os_name == "nt"',
'importlib-metadata >= 4.6; python_full_version < "3.10.2"', # Not required for 3.8+, but fixes a stdlib bug
'tomli >= 1.1.0; python_version < "3.11"',
]
[project.optional-dependencies]
docs = [
"furo >= 2023.08.17",
"sphinx ~= 7.0",
"sphinx-argparse-cli >= 1.5",
"sphinx-autodoc-typehints >= 1.10",
"sphinx-issues >= 3.0.0",
]
test = [
"build[uv, virtualenv]",
"filelock >= 3",
"pytest >= 6.2.4",
"pytest-cov >= 2.12",
"pytest-mock >= 2",
"pytest-rerunfailures >= 9.1",
"pytest-xdist >= 1.34",
"wheel >= 0.36.0",
'setuptools >= 42.0.0; python_version < "3.10"',
'setuptools >= 56.0.0; python_version == "3.10"',
'setuptools >= 56.0.0; python_version == "3.11"',
'setuptools >= 67.8.0; python_version >= "3.12"',
]
typing = [
"build[uv]",
"importlib-metadata >= 5.1",
"mypy ~= 1.9.0",
"tomli",
"typing-extensions >= 3.7.4.3",
]
uv = [
"uv >= 0.1.18",
]
virtualenv = [
"virtualenv >= 20.0.35",
]
[project.scripts]
pyproject-build = "build.__main__:entrypoint"
[project.entry-points."pipx.run"]
build = "build.__main__:entrypoint"
[tool.flit.sdist]
include = ["tests/", ".gitignore", "CHANGELOG.rst", "docs/", ".dockerignore", "tox.ini"]
exclude = ["**/__pycache__", "docs/_build", "**/*.egg-info", "tests/packages/*/build"]
[tool.coverage.run]
source = [
"build",
"tests",
]
[tool.coverage.report]
exclude_also = [
'^\s*raise NotImplementedError\b',
"if typing.TYPE_CHECKING:",
]
[tool.coverage.paths]
build = [
"src",
"*/site-packages",
'*\site-packages',
]
[tool.coverage.html]
show_contexts = true
[tool.pytest.ini_options]
minversion = "6.0"
addopts = ["--strict-config", "--strict-markers"]
log_cli_level = "info"
testpaths = ["tests"]
xfail_strict = true
junit_family = "xunit2"
norecursedirs = "tests/integration/*"
markers = [
"contextvars",
"isolated",
"pypy3323bug",
"network",
]
filterwarnings = [
"error",
"ignore:path is deprecated.:DeprecationWarning",
"ignore:The --rsyncdir command line argument and rsyncdirs config variable are deprecated.:DeprecationWarning",
"default:Python 3.14 will, by default, filter extracted tar archives:DeprecationWarning",
]
[tool.mypy]
files = "src"
python_version = "3.8"
strict = true
show_error_codes = true
enable_error_code = ["ignore-without-code", "truthy-bool", "redundant-expr"]
[[tool.mypy.overrides]]
module = [
"colorama", # Optional dependency
"virtualenv", # Optional dependency
]
ignore_missing_imports = true
[tool.ruff]
exclude = [
"tests/packages/*/pyproject.toml",
"tests/packages/test-bad-syntax",
]
line-length = 127
[tool.ruff.format]
quote-style = "single"
[tool.ruff.lint]
extend-select = [
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"C9", # mccabe
"I", # isort
"PGH", # pygrep-hooks
"RUF", # ruff
"UP", # pyupgrade
"W", # pycodestyle
"YTT", # flake8-2020
"TRY", # tryceratops
"EM", # flake8-errmsg
]
[tool.ruff.lint.mccabe]
max-complexity = 10
[tool.ruff.lint.isort]
lines-between-types = 1
lines-after-imports = 2
[tool.check-wheel-contents]
ignore = [
"W005", # We _are_ build
]
[tool.bumpversion]
current_version = "1.0.0"
[[tool.bumpversion.files]]
filename = "pyproject.toml"
search = 'version = "{current_version}"'
[[tool.bumpversion.files]]
filename = "src/build/__init__.py"
search = "__version__ = '{current_version}'"