-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
187 lines (158 loc) · 4.1 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
[build-system]
requires = [
"extension-helpers",
"setuptools>=45",
"wheel"
]
build-backend = 'setuptools.build_meta'
[project]
name = "bound_class.core"
version = "0.1.0"
description = "Classes bound to another class."
readme = "README.rst"
requires-python = ">=3.8"
license = {file = "LICENSE"}
keywords = ["python"]
authors = [
{name = "Nathaniel Starkman", email = "[email protected]"}
]
maintainers = [
{name = "Nathaniel Starkman", email = "[email protected]"}
]
classifiers = [
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
]
dependencies = [
"typing_extensions>=4.2",
"mypy_extensions",
]
[project.optional-dependencies]
test = [
"coverage[toml]",
"pytest",
"pytest-astropy-header",
"pytest-cov",
"pytest-doctestplus",
"pytest-filter-subpackage",
]
docs = [
"IPython",
"jupyter_client",
"nbsphinx",
"numpydoc",
"pydata_sphinx_theme",
"sphinx",
"sphinx_automodapi",
"sphinxcontrib.bibtex",
"tomli",
]
[project.urls]
homepage = "https://bound_class.readthedocs.io"
repository = "https://github.com/nstarman/bound-class"
documentation = "https://bound_class.readthedocs.io"
[tool.setuptools]
[tool.setuptools.packages.find]
where = ["src"]
[tool.setuptools.package-data]
"*" = ["py.typed"]
[tool.black]
line-length = 120
include = '\.pyi?$'
exclude = '''
/(
\.git
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| _build
| buck-out
| build
| dist
)/
'''
[tool.coverage.run]
omit = [
"*/conftest.py",
"*/setup_package.py",
"*/tests/*",
]
[tool.coverage.report]
exclude_lines = [
# Have to re-enable the standard pragma
"pragma: no cover",
# Don't complain about packages we have installed
"except ImportError",
# Don't complain if tests don't hit assertions
"raise AssertionError",
"raise NotImplementedError",
# Don't complain about script hooks
"'def main(.*):'",
# Ignore branches that don't pertain to this version of Python
"pragma: py{ignore_python_version}",
# Don't complain about IPython completion helper
"def _ipython_key_completions_",
]
[tool.mypy]
python_version = 3.9
namespace_packages = true
explicit_package_bases = true
mypy_path = "$MYPY_CONFIG_FILE_DIR/src"
strict = true
disallow_subclassing_any = false
show_error_codes = true
show_error_context = true
show_column_numbers = true
pretty = true
[[tool.mypy.overrides]]
module = "tests/*"
ignore_errors = true
[[tool.mypy.overrides]]
module = "docs/*"
ignore_errors = true
[[tool.mypy.overrides]]
module = "pytest.*"
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = "pytest_astropy_header.display.*"
ignore_missing_imports = true
[tool.pytest.ini_options]
testpaths = ["tests", "docs"]
astropy_header = "True"
doctest_plus = "enabled"
text_file_format = "rst"
addopts = [
'--doctest-rst',
'--import-mode=importlib',
]
filterwarnings = [
# distutils
"ignore:distutils Version classes are deprecated. Use packaging.version instead."
]
[tool.ruff]
target-version = "py38"
line-length = 120
[tool.ruff.lint]
select = ["ALL"]
ignore = [
"ANN101", # Missing type annotation for self in method
"COM812", # Missing trailing comma
"D105", # Missing docstring in magic method
"D107", # Missing docstring in __init__
"D203", # 1 blank line required before class docstring
"D213", # Multi-line docstring summary should start at the second line
"D401",
# flake8-fixme (FIX)
"FIX002", # Line contains TODO
# Pylint (PL)
"PLC0105", # `TypeVar` name does not reflect its covariance;
# flake8-todos (TD)
"TD002", # Missing author in TODO
"TD003", # Missing issue link on the line following this TODO
]
[tool.ruff.lint.per-file-ignores]
"docs/*.py" = ["INP001"]
"tests/*.py" = ["ANN", "D", "N8", "PLR2004", "S101", "SLF001"]