From 1cdb3b4dd6d23923445e20636d784d1f38b85967 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Thu, 23 May 2024 19:24:05 -0700 Subject: [PATCH] [pre-commit.ci] pre-commit autoupdate (#328) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .pre-commit-config.yaml | 2 +- pyproject.toml | 43 ++++++++++++++++++++--------------------- 2 files changed, 22 insertions(+), 23 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 80e8fdc..32b453e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,7 +15,7 @@ repos: - id: tox-ini-fmt args: ["-p", "fix"] - repo: https://github.com/tox-dev/pyproject-fmt - rev: "2.0.3" + rev: "2.1.1" hooks: - id: pyproject-fmt additional_dependencies: ["tox>=4.12.1"] diff --git a/pyproject.toml b/pyproject.toml index 35daa4b..09e57a7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,41 +72,40 @@ build.targets.sdist.include = [ version.source = "vcs" [tool.ruff] -line-length = 120 target-version = "py38" +line-length = 120 +format.preview = true +format.docstring-code-line-length = 100 +format.docstring-code-format = true +lint.select = [ + "ALL", +] +lint.per-file-ignores."tests/**/*.py" = [ + "D", # don"t care about documentation in tests + "FBT", # don"t care about booleans as positional arguments in tests + "INP001", # no implicit namespace + "PLR2004", # Magic value used in comparison, consider replacing with a constant variable + "S101", # asserts allowed in tests... + "S603", # `subprocess` call: check for execution of untrusted input +] lint.isort = { known-first-party = [ "filelock", ], required-imports = [ "from __future__ import annotations", ] } -lint.select = [ - "ALL", -] lint.ignore = [ "ANN101", # Missing type annotation for `self` in method - "D301", # Use `r"""` if any backslashes in a docstring - "D205", # 1 blank line required between summary line and description - "D401", # First line of docstring should be in imperative mood + "COM812", # Conflict with formatter + "CPY", # No copyright statements "D203", # `one-blank-line-before-class` (D203) and `no-blank-line-before-class` (D211) are incompatible + "D205", # 1 blank line required between summary line and description "D212", # `multi-line-summary-first-line` (D212) and `multi-line-summary-second-line` (D213) are incompatible - "S104", # Possible binding to all interface - "COM812", # Conflict with formatter + "D301", # Use `r"""` if any backslashes in a docstring + "D401", # First line of docstring should be in imperative mood "ISC001", # Conflict with formatter - "CPY", # No copyright statements + "S104", # Possible binding to all interface ] lint.preview = true -format.preview = true -format.docstring-code-format = true -format.docstring-code-line-length = 100 -[tool.ruff.lint.per-file-ignores] -"tests/**/*.py" = [ - "S101", # asserts allowed in tests... - "FBT", # don"t care about booleans as positional arguments in tests - "INP001", # no implicit namespace - "D", # don"t care about documentation in tests - "S603", # `subprocess` call: check for execution of untrusted input - "PLR2004", # Magic value used in comparison, consider replacing with a constant variable -] [tool.codespell] builtin = "clear,usage,en-GB_to_en-US"