From f9206d1ef84e2dc7c9defe23de184104f6772875 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 15 Sep 2025 21:19:15 +0000 Subject: [PATCH 1/2] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/astral-sh/ruff-pre-commit: v0.12.12 → v0.13.0](https://github.com/astral-sh/ruff-pre-commit/compare/v0.12.12...v0.13.0) - [github.com/pre-commit/mirrors-mypy: v1.17.1 → v1.18.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.17.1...v1.18.1) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b9009f4..7af7bca 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,7 +9,7 @@ ci: repos: - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.12.12 + rev: v0.13.0 hooks: - id: ruff args: [--fix] @@ -38,7 +38,7 @@ repos: - id: isort - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.17.1 + rev: v1.18.1 hooks: - id: mypy # uses py311 syntax, mypy configured for py39 From 8b01599518d353e8408d7fbbf1cb6d1de476726b Mon Sep 17 00:00:00 2001 From: Zac Hatfield-Dodds Date: Mon, 15 Sep 2025 23:51:54 -0700 Subject: [PATCH 2/2] fix linter errs --- .pre-commit-config.yaml | 2 +- tests/test_exception_on_invalid_code.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7af7bca..0d3a686 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -11,7 +11,7 @@ repos: - repo: https://github.com/astral-sh/ruff-pre-commit rev: v0.13.0 hooks: - - id: ruff + - id: ruff-check args: [--fix] - repo: https://github.com/psf/black diff --git a/tests/test_exception_on_invalid_code.py b/tests/test_exception_on_invalid_code.py index dec3fd1..2df13ef 100644 --- a/tests/test_exception_on_invalid_code.py +++ b/tests/test_exception_on_invalid_code.py @@ -10,7 +10,7 @@ def _raises_on_code_cst(source: str): expression = cst.parse_expression(source) - with pytest.raises(RuntimeError, match="Invalid literal values.*"): + with pytest.raises(RuntimeError, match="Invalid literal values"): iter_guaranteed_once_cst(expression) @@ -24,7 +24,7 @@ def _raises_on_code_ast(source: str): assert isinstance(expression, ast.Expr) call = expression.value assert isinstance(call, ast.Call) - with pytest.raises(RuntimeError, match="Invalid literal values.*"): + with pytest.raises(RuntimeError, match="Invalid literal values"): iter_guaranteed_once(call)