From ac4fac4ac9577147561ccb6ef8e3ced3a6706e91 Mon Sep 17 00:00:00 2001 From: Anthony Ant Hillairet Date: Mon, 11 Aug 2025 08:24:18 -0700 Subject: [PATCH 1/2] chore: update ruff in pre-commit --- template/.pre-commit-config.yaml | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/template/.pre-commit-config.yaml b/template/.pre-commit-config.yaml index c1879a0..2a30aeb 100644 --- a/template/.pre-commit-config.yaml +++ b/template/.pre-commit-config.yaml @@ -2,33 +2,34 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.4.0 hooks: - - id: check-case-conflict - - id: check-merge-conflict - - id: debug-statements + - id: check-case-conflict + - id: check-merge-conflict + - id: debug-statements exclude: ^backend/{{ copier__project_slug }}/utils/debugger.py - - id: detect-aws-credentials + - id: detect-aws-credentials args: ["--allow-missing-credentials"] - - id: detect-private-key + - id: detect-private-key - repo: https://github.com/psf/black rev: 23.9.1 hooks: - - id: black + - id: black - repo: https://github.com/pycqa/isort rev: 5.12.0 hooks: - - id: isort + - id: isort args: ["--profile", "black", "--filter-files"] - - repo: https://github.com/charliermarsh/ruff-pre-commit - rev: 'v0.0.290' + - repo: https://github.com/astral-sh/ruff-pre-commit + rev: v0.12.8 hooks: - - id: ruff + # Run the linter. + - id: ruff-check args: ["--ignore", "E501"] - repo: https://github.com/PyCQA/bandit rev: 1.7.5 hooks: - - id: bandit + - id: bandit args: ["-ll"] From 9469f4993de4619352dd53d58849852bab637a45 Mon Sep 17 00:00:00 2001 From: Anthony Ant Hillairet Date: Mon, 11 Aug 2025 10:45:30 -0700 Subject: [PATCH 2/2] chore: add missing rules to match flake8 --- template/.pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/template/.pre-commit-config.yaml b/template/.pre-commit-config.yaml index 2a30aeb..314c101 100644 --- a/template/.pre-commit-config.yaml +++ b/template/.pre-commit-config.yaml @@ -26,7 +26,7 @@ repos: hooks: # Run the linter. - id: ruff-check - args: ["--ignore", "E501"] + args: ["--ignore", "E501", "--extend-select", "E,W"] - repo: https://github.com/PyCQA/bandit rev: 1.7.5