diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 99128e5..9e9f4e8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -18,7 +18,7 @@ repos: hooks: - id: tox-ini-fmt - repo: https://github.com/tox-dev/pyproject-fmt - rev: "2.0.4" + rev: "2.1.1" hooks: - id: pyproject-fmt additional_dependencies: ["tox>=4.9"] diff --git a/pyproject.toml b/pyproject.toml index cf310e0..4ea23c3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -69,11 +69,13 @@ target-version = [ ] [tool.ruff] +target-version = "py39" + +line-length = 88 src = [ "src", "tests", ] -fix = true exclude = [ ".git", ".mypy_cache", @@ -83,6 +85,7 @@ exclude = [ "migrations", "venv", ] +fix = true ignore = [ "DJ001", # Allow null=True "DJ008", # Don't require a __str__ method @@ -91,7 +94,6 @@ ignore = [ "S101", # Allow asserts "TRY003", # We don't care about length of messages for exception classes ] -line-length = 88 select = [ "A", "B", @@ -129,30 +131,21 @@ select = [ "W", "YTT", ] -target-version = "py39" - -[tool.ruff.per-file-ignores] -"tests/**" = [ +mccabe.max-complexity = 8 +per-file-ignores."tests/**" = [ "S105", "S106", ] - -[tool.ruff.mccabe] -max-complexity = 8 - -[tool.ruff.isort] -known-first-party = [ - "src/", - "tests/", -] -combine-as-imports = true - -[tool.ruff.pylint] -allow-magic-value-types = [ +pylint.allow-magic-value-types = [ "str", "bytes", "int", ] +isort.known-first-party = [ + "src/", + "tests/", +] +isort.combine-as-imports = true [tool.coverage.paths] source = [