From c6c6d214172f875d68988272a5c059997454b083 Mon Sep 17 00:00:00 2001 From: Yifan Lu Date: Tue, 10 Nov 2026 15:28:36 -0600 Subject: [PATCH] CI: drop the Python 3.9 MyPy job, which the runner image no longer supports GitHub's ubuntu-latest runners moved to Ubuntu 26.04, where setup-python has no Python 3.9 ("The version '3.9' with architecture 'x64' was not found"), so MyPy (3.9) fails on every PR and cancels the other versions' jobs. pyproject.toml supports >3.10,<3.13, so the matrix becomes 3.10-3.12 and the unused mypy-3.9 hook is removed. fail-fast is off, so one version's failure no longer cancels the rest. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/pre-commit.yml | 5 ++++- .pre-commit-config.yaml | 8 -------- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index 2570a046..f36c34e3 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -28,8 +28,11 @@ jobs: name: MyPy (${{ matrix.python-version }}) runs-on: ubuntu-latest strategy: + # One version's failure shouldn't cancel the others' runs. + fail-fast: false matrix: - python-version: ["3.9", "3.10", "3.11", "3.12"] + # The versions pyproject.toml supports (>3.10,<3.13). + python-version: ["3.10", "3.11", "3.12"] steps: - uses: actions/checkout@v5 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c08b7443..8eb67199 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -91,14 +91,6 @@ repos: pass_filenames: false additional_dependencies: &mypy_deps [mypy==1.11.1, types-cachetools, types-setuptools, types-PyYAML, types-requests, pydantic] stages: [pre-commit] # Don't run in CI - - id: mypy-3.9 - name: Run mypy for Python 3.9 - entry: tools/mypy.sh 1 "3.9" - language: python - types: [python] - pass_filenames: false - additional_dependencies: *mypy_deps - stages: [manual] # Only run in CI - id: mypy-3.10 name: Run mypy for Python 3.10 entry: tools/mypy.sh 1 "3.10"