Skip to content

Commit a10edba

Browse files
authored
Coalesce ruff config into pyproject.yoml (#90)
1 parent 2b582be commit a10edba

File tree

2 files changed

+33
-34
lines changed

2 files changed

+33
-34
lines changed

pyproject.toml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,3 +124,36 @@ exclude_lines = [
124124
"raise AssertionError",
125125
"raise NotImplementedError",
126126
]
127+
128+
[tool.ruff]
129+
# Same as Black line length
130+
line-length = 88
131+
132+
# Python version compatibility
133+
target-version = "py310"
134+
135+
[tool.ruff.lint]
136+
# Enable rules that replace the tools we're removing:
137+
# - F: Pyflakes (basic linting)
138+
# - E, W: pycodestyle errors and warnings
139+
# - I: isort (import sorting)
140+
# - UP: pyupgrade (modern Python idioms, but be selective)
141+
select = ["F", "E", "W", "I", "UP031", "UP008"]
142+
143+
# Ignore some rules that might be too strict for existing code
144+
ignore = [
145+
"E501", # Line too long (handled by formatter)
146+
"E741", # Ambiguous variable name (too restrictive for this codebase)
147+
"E722", # Do not use bare except (existing code pattern)
148+
]
149+
150+
[tool.ruff.lint.isort]
151+
# Match the existing isort configuration (black-compatible)
152+
force-single-line = false
153+
combine-as-imports = true
154+
known-first-party = ["lab_validation", "lab_tests"]
155+
156+
[tool.ruff.format]
157+
# Use Black-compatible formatting
158+
quote-style = "double"
159+
indent-style = "space"

ruff.toml

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)