From 15aef7d5e5a593340e9cc83caa7e2e96aa1e0eb7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 7 May 2026 13:10:16 +0100 Subject: [PATCH 1/3] Enable mypy parallel workers in pre-commit. Co-authored-by: Cursor --- .pre-commit-config.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2156fa8e..9cc02b74 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -157,7 +157,7 @@ repos: - id: mypy name: mypy stages: [pre-push] - entry: uv run --extra=dev -m mypy + entry: uv run --extra=dev -m mypy --num-workers=4 language: python types_or: [python, toml] pass_filenames: false @@ -168,7 +168,8 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy + --num-workers=4" language: python types_or: [markdown, rst] additional_dependencies: From 49550db9bc56660a217b44ba073b9c39a3281f3d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 7 May 2026 13:32:35 +0100 Subject: [PATCH 2/3] Normalize mypy docs pre-commit worker flag style. Keep `mypy-docs` aligned with `mypy` by keeping `--num-workers=4` inline in the mypy command argument. Co-authored-by: Cursor --- .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 9cc02b74..0a0debcf 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -168,8 +168,8 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy - --num-workers=4" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python + args: [--command=mypy --num-workers=4] language: python types_or: [markdown, rst] additional_dependencies: From 2d87cce6d3703693764cc923f869fed20596044a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 7 May 2026 13:35:45 +0100 Subject: [PATCH 3/3] Inline mypy-docs command to keep worker flags together. Co-authored-by: Cursor --- .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 0a0debcf..9cc02b74 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -168,8 +168,8 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python - args: [--command=mypy --num-workers=4] + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy + --num-workers=4" language: python types_or: [markdown, rst] additional_dependencies: