-
Notifications
You must be signed in to change notification settings - Fork 1
/
pyproject.toml
170 lines (158 loc) · 3.08 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
[build-system]
build-backend = "hatchling.build"
requires = [
"hatch-vcs",
"hatchling",
]
[project]
name = "bankid-sdk"
description = "A Python SDK for BankID"
readme = "README.md"
keywords = [
"bankid",
"client",
"django",
"rest",
]
license = "BSD-3-Clause"
authors = [{ name = "Jonas Lundberg", email = "[email protected]" }]
requires-python = ">=3.9"
classifiers = [
"Development Status :: 4 - Beta",
"Framework :: Django",
"Framework :: Django :: 4.1",
"Framework :: Django :: 4.2",
"Framework :: Django :: 5.0",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Typing :: Typed",
]
dynamic = [
"version",
]
dependencies = [
"abcattrs",
"httpx",
]
optional-dependencies.dev = [
"bankid-sdk[test]",
"mypy",
"pre-commit",
]
optional-dependencies.django = [
"django",
]
optional-dependencies.test = [
"bankid-sdk[django]",
"dirty-equals",
"django-stubs",
"freezegun",
"pytest",
"pytest-asyncio",
"pytest-cov",
"pytest-django",
"pytest-randomly",
"respx",
]
urls.Homepage = "https://github.com/5monkeys/bankid-sdk"
urls.Source = "https://github.com/5monkeys/bankid-sdk"
urls.Tracker = "https://github.com/5monkeys/bankid-sdk/issues"
[tool.hatch]
build.hooks.vcs.version-file = "src/bankid_sdk/_version.py"
version.source = "vcs"
[tool.black]
target-version = ["py39"]
[tool.ruff]
src = ["src", "tests"]
fix = true
target-version = "py39"
line-length = 88
select = [
"B",
"BLE",
"C4",
"C9",
"C90",
"DJ006",
"DJ007",
"DJ012",
"DTZ",
"E",
"EXE",
"F",
"FA",
"FBT",
"I",
"INP",
"ISC",
"PGH",
"PIE",
"PL",
"PT",
"PTH",
"RET",
"RSE",
"RUF",
"S",
"SIM",
"SLOT",
"T10",
"T20",
"TID",
"TRY",
"UP",
"W",
"YTT"
]
ignore = [
# We've deemed ourselves good designers of our interfaces and would only have
# motivated ignores.
"PLR0913",
"RET505", # Don't like this opinion
"S101",
"TRY003", # Don't care about length of messages for exception classes
]
[tool.ruff.per-file-ignores]
"tests/**" = ["PLR2004", "S105", "S106"]
[tool.ruff.isort]
known-first-party = ["bankid_sdk", "tests"]
combine-as-imports = true
[tool.pytest.ini_options]
testpaths = ["tests", "src"]
addopts = "--cov --no-cov-on-fail"
asyncio_mode = "auto"
[tool.coverage.paths]
source = [
"src/bankid_sdk",
".tox/*/lib/*/site-packages/bankid_sdk",
]
[tool.coverage.report]
skip_covered = true
show_missing = true
exclude_also = [
# ignore non-implementations
'^\s*\.\.\.',
"if TYPE_CHECKING:",
'^\s*(def\s)?assert_never(.*)$',
]
fail_under = 100
[tool.coverage.run]
parallel = true
branch = true
source = ["bankid_sdk", "tests"]
[tool.mypy]
python_version = "3.9"
pretty = true
show_error_codes = true
files = "src, tests"
no_implicit_optional = true
strict_optional = true
ignore_missing_imports = false
warn_unreachable = true
strict = true