forked from archlinux/archinstall
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
223 lines (194 loc) · 5.17 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
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
[build-system]
requires = ["setuptools>=67.5"]
build-backend = "setuptools.build_meta"
[project]
name = "archinstall"
dynamic = ["version"]
description = "Arch Linux installer - guided, templates etc."
authors = [
{name = "Anton Hvornum", email = "[email protected]"},
]
license = {text = "GPL-3.0-only"}
readme = "README.md"
requires-python = ">=3.12"
keywords = ["linux", "arch", "archinstall", "installer"]
classifiers = [
"Programming Language :: Python :: 3.12",
"Operating System :: POSIX :: Linux",
]
dependencies = [
"pyparted @ https://github.com//dcantrell/pyparted/archive/v3.13.0.tar.gz#sha512=26819e28d73420937874f52fda03eb50ab1b136574ea9867a69d46ae4976d38c4f26a2697fa70597eed90dd78a5ea209bafcc3227a17a7a5d63cff6d107c2b11",
"pydantic==2.10.3"
]
[project.urls]
Home = "https://archlinux.org"
Documentation = "https://archinstall.readthedocs.io/"
Source = "https://github.com/archlinux/archinstall"
[project.optional-dependencies]
log = ["systemd_python==235"]
dev = [
"mypy==1.13.0",
"flake8==7.1.1",
"pre-commit==4.0.1",
"ruff==0.8.3",
"pylint==3.3.2",
"pylint-pydantic==0.3.4",
"pytest==8.3.4",
]
doc = ["sphinx"]
[project.scripts]
archinstall = "archinstall:run_as_a_module"
[tool.setuptools.dynamic]
version = {attr = "archinstall.__version__"}
readme = {file = ["README.rst", "USAGE.rst"]}
[tool.setuptools]
include-package-data = true
[tool.setuptools.package-data]
# We could specify locales/languages.json etc instead, but catchall works too.
"archinstall" = [
"**/*.py",
"**/*.mo",
"**/*.po",
"**/*.pot",
"**/*.json",
]
[tool.setuptools.package-dir]
archinstall = "archinstall"
[tool.mypy]
python_version = "3.12"
files = "."
exclude = "^build/"
check_untyped_defs = true
disallow_any_explicit = false
disallow_any_expr = false
disallow_any_generics = true
disallow_any_unimported = true
disallow_incomplete_defs = true
disallow_subclassing_any = true
disallow_untyped_calls = true
disallow_untyped_decorators = true
disallow_untyped_defs = true
extra_checks = true
strict = false
strict_equality = true
warn_redundant_casts = true
warn_return_any = true
warn_unreachable = true
warn_unused_configs = true
warn_unused_ignores = true
[[tool.mypy.overrides]]
module = "archinstall.default_profiles.*"
disallow_any_explicit = true
[[tool.mypy.overrides]]
module = "archinstall.examples.*"
disallow_any_explicit = true
[[tool.mypy.overrides]]
module = "archinstall.lib.*"
disallow_any_generics = false
disallow_any_unimported = false
disallow_incomplete_defs = false
disallow_untyped_defs = false
warn_return_any = false
warn_unreachable = false
[[tool.mypy.overrides]]
module = "archinstall.lib.packages"
disallow_any_explicit = true
[[tool.mypy.overrides]]
module = "archinstall.lib.utils"
disallow_any_explicit = true
[[tool.mypy.overrides]]
module = "archinstall.scripts.*"
warn_unreachable = false
[[tool.mypy.overrides]]
module = "archinstall.tui.*"
warn_unreachable = false
[[tool.mypy.overrides]]
module = [
"parted",
]
ignore_missing_imports = true
[tool.bandit]
targets = ["archinstall"]
exclude = ["/tests"]
[tool.pytest.ini_options]
pythonpath = ["."]
addopts = "-s"
testpaths = ["tests"]
[tool.pylint.main]
ignore-paths = [
"^build/",
"^docs/",
]
load-plugins = ["pylint_pydantic"]
persistent = false
py-version = "3.12"
recursive = true
[tool.pylint.format]
indent-string = '\t'
max-line-length = 160
[tool.pylint."messages control"]
disable = [
"C",
"R",
"attribute-defined-outside-init",
"broad-exception-caught",
"cell-var-from-loop",
"dangerous-default-value",
"fixme",
"protected-access",
"raise-missing-from",
"unspecified-encoding",
"unused-argument",
]
[tool.pylint.refactoring]
score = false
[tool.pylint.variables]
additional-builtins = ["_"]
[tool.ruff]
target-version = "py312"
builtins = ["_"]
line-length = 160
[tool.ruff.lint]
select = [
"ASYNC", # flake8-async
"C90", # mccabe
"DTZ", # flake8-datetimez
"E", # pycodestyle errors
"EXE", # flake8-executable
"F", # Pyflakes
"FA", # flake8-future-annotations
"FLY", # flynt
"G", # flake8-logging-format
"I", # isort
"ICN", # flake8-import-conventions
"ISC", # flake8-implicit-str-concat
"LOG", # flake8-logging
"PIE", # flake8-pie
"PLC", # Pylint conventions
"PLE", # Pylint errors
"PLW", # Pylint warnings
"RSE", # flake8-raise
"RUF", # Ruff-specific rules
"SLOT", # flake8-slot
"T10", # flake8-debugger
"UP", # pyupgrade
"W", # pycodestyle warnings
"YTT", # flake8-2020
]
ignore = [
"PLC0415", # import-outside-top-level
"PLC1901", # compare-to-empty-string
"PLW1514", # unspecified-encoding
"PLW1641", # eq-without-hash
"PLW2901", # redefined-loop-name
"RUF005", # collection-literal-concatenation
"RUF012", # mutable-class-default
"RUF015", # unnecessary-iterable-allocation-for-first-element
"RUF039", # unraw-re-pattern
"UP037", # quoted-annotation
"W191", # tab-indentation
]
[tool.ruff.lint.mccabe]
max-complexity = 40
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401"] # unused-import