-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
92 lines (85 loc) · 2.88 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
[build-system]
build-backend = "hatchling.build"
requires = [ "hatch-docstring-description", "hatch-vcs", "hatchling" ]
[project]
name = "legacy-api-wrap"
readme = "README.rst"
license = "MPL-2.0"
authors = [ { name = "Philipp A.", email = "flying-sheep@web.de" } ]
requires-python = ">=3.8"
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"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",
"Topic :: Software Development :: Libraries :: Python Modules",
"Typing :: Typed",
]
dynamic = [ "description", "version" ]
dependencies = [ ]
optional-dependencies.test = [
"anyconfig[toml]>=0.14", # coverage-rich uses anyconfig
"coverage",
"coverage-rich",
"pytest",
"typer<0.14", # https://github.com/WaylonWalker/coverage-rich/issues/4
]
urls.Source = "https://github.com/flying-sheep/legacy-api-wrap"
[tool.hatch.version]
source = "vcs"
[tool.hatch.build.targets.wheel]
packages = [ "src/legacy_api_wrap", "src/testing/legacy_api_wrap" ]
[tool.hatch.envs.hatch-test]
default-args = [ ]
features = [ "test" ]
scripts.run = "pytest{env:HATCH_TEST_ARGS:} {args}"
scripts.run-cov = "coverage run -m pytest{env:HATCH_TEST_ARGS:} {args}"
scripts.cov-combine = "coverage combine"
scripts.cov-report = "coverage-rich report"
[[tool.hatch.envs.test.matrix]]
python = [ "3.8", "3.13" ]
[tool.ruff]
line-length = 100
lint.select = [ "ALL" ]
lint.ignore = [
"COM812", # incompatible with formatter
"D203", # zero instead of one blank lines before class
"D213", # multiline summary on first instead of second line
"ISC001", # incompatible with formatter
]
lint.extend-per-file-ignores."src/testing/*.py" = [ "INP001" ]
lint.extend-per-file-ignores."tests/**/test_*.py" = [
"D100", # tests need no module docstrings
"D103", # tests need no function docstrings
"INP001", # tests should not have __init__.py
"PLR2004", # tests use magic values
"S101", # tests use `assert`
]
lint.allowed-confusables = [ "’" ]
lint.flake8-copyright.notice-rgx = "SPDX-License-Identifier: MPL-2\\.0"
lint.isort.known-first-party = [ "legacy_api_wrap" ]
lint.isort.required-imports = [ "from __future__ import annotations" ]
[tool.pytest.ini_options]
addopts = [
"--import-mode=importlib",
"--strict-markers",
"-Werror",
"-ptesting.legacy_api_wrap.pytest",
"--doctest-modules",
"--doctest-glob=*.rst",
]
[tool.coverage]
run.data_file = "test-data/coverage"
xml.output = "test-data/coverage.xml"
html.directory = "test-data/htmlcov"
run.omit = [ "src/testing/*", "tests/*" ]
report.exclude_also = [ "if TYPE_CHECKING:" ]
[tool.mypy]
strict = true
explicit_package_bases = true
mypy_path = "src"