Skip to content

Commit

Permalink
Update ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
hynek committed Feb 2, 2024
1 parent 75d54c2 commit 151ef89
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ ci:

repos:
- repo: https://github.com/psf/black
rev: 24.1.0
rev: 24.1.1
hooks:
- id: black

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.1.14
rev: v0.2.0
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ toplevel = ["attr", "attrs"]
[tool.ruff]
src = ["src", "tests", "conftest.py", "docs"]

[tool.lint.ruff]
select = ["ALL"]
ignore = [
"A001", # shadowing is fine
Expand All @@ -185,7 +186,6 @@ ignore = [
"PLR0911", # we're complex software
"PLR0912", # we're complex software
"PLR0915", # we're complex software
"PGH001", # eval FTW
"S307", # eval FTW
"N807", # we need to create functions that start with __
"ERA001", # we need to keep around some notes
Expand All @@ -197,7 +197,7 @@ ignore = [
"TRY301", # I'm sorry, but this makes not sense for us.
]

[tool.ruff.per-file-ignores]
[tool.ruff.lint.per-file-ignores]
"**/test_*" = [
"ARG005", # we need stub lambdas
"S",
Expand Down Expand Up @@ -233,7 +233,7 @@ ignore = [
"UP037", # we test some older syntaxes on purpose
]

[tool.ruff.isort]
[tool.ruff.lint.isort]
lines-between-types = 1
lines-after-imports = 2
known-first-party = ["attr", "attrs"]
Expand Down

0 comments on commit 151ef89

Please sign in to comment.