Skip to content

Commit 2b53d08

Browse files
committed
add styles pyproject
1 parent 16bd1ac commit 2b53d08

2 files changed

Lines changed: 35 additions & 0 deletions

File tree

pyproject.toml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
[tool.ruff]
2+
target-version = "py312"
3+
extend = "./styles/ruff.toml"
4+
include = ["src/*"]
5+
exclude = ["src/vendors/*", "guides/*"]
6+
7+
[tool.ruff.lint]
8+
ignore = [
9+
"BLE001", # Allow blind exception catch
10+
"T201", # Allow prints
11+
"TRY002", # Create own exception
12+
"TRY301", # Allow raising exceptions
13+
"DOC201", # Don't require returns in doc
14+
"DOC501", # Don't require raises in doc
15+
]
16+
[tool.ruff.lint.per-file-ignores]
17+
"src/brokerages/*" = [
18+
"PLR0913", # Allow too many arguments
19+
"PLR1702", # Allow many nested blocks
20+
]

styles/ruff.toml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
line-length = 320 # I don't like text wrapping
2+
indent-width = 4
3+
preview = true
4+
5+
[format]
6+
line-ending = "lf"
7+
8+
[lint]
9+
select = ["ALL"]
10+
ignore = [
11+
"CPY001", # Ignore license header checks
12+
"D100", # Ignore missing doc strings in modules
13+
"D203", # Conflicts with D211 (we like no blank line before class docstring)
14+
"D213", # Conflicts with D212 (we like first docstring line at top)
15+
]

0 commit comments

Comments
 (0)