-
Notifications
You must be signed in to change notification settings - Fork 47
/
pyproject.toml
42 lines (39 loc) · 1.48 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
[tool.ruff]
# Ensure suggested fixes are compatible with our minimum supported version
# XXX: Currently this is py36, but the minimum supported by ruff is py37.
target-version = "py37"
line-length = 120
src = ["pycheribuild", "release-scripts", "test-scripts", "tests"]
exclude = [
".git",
".idea",
".run",
".pytype/",
".venv",
"3rdparty",
"venv",
]
output-format = "full"
show-fixes = true
[tool.ruff.lint]
select = ["E", "F", "I", "N", "W", "U", "COM", "RUF", "PLC", "PLE", "PLW"]
ignore = [
"UP037", # Remove quotes from type annotation, not possible until we start using 3.7 as the minimum
"UP036", # 'Version block is outdated for minimum Python version' to be removed when we set the minimum to 3.8
"PLW2901", # `for` loop variable `value` overwritten by assignment target
"RUF012", # Mutable class attributes should be annotated with `typing.ClassVar` (cannot be fixed due to bug)
"COM812", # Incompatible with `ruff format`
"PLC0415", # `import` should be at the top-level of a file
]
[tool.ruff.lint.isort]
relative-imports-order = "closest-to-furthest"
known-local-folder = ["pycheribuild"]
[tool.black]
line-length = 120
target-version = ['py36']
# 'extend-exclude' excludes files or directories in addition to the defaults
# Currently reformatting pycheribuild/ results in lots of weird formatting, so
# let's restrict this to the other files for now.
extend-exclude = '''3rdparty|\.pytype|pycheribuild'''
preview = true
required-version = '23'