From 312d836a616f693324b8092cdc8e3607c5dced86 Mon Sep 17 00:00:00 2001 From: Sebastian Rittau Date: Mon, 9 Feb 2026 12:37:36 +0100 Subject: [PATCH] Remove 3.9 support from CI and tests Part of #15358. --- .github/workflows/daily.yml | 2 +- .github/workflows/meta_tests.yml | 2 +- .github/workflows/stubtest_stdlib.yml | 2 +- .github/workflows/tests.yml | 4 ++-- tests/mypy_test.py | 2 +- tests/regr_test.py | 2 +- tests/runtests.py | 2 +- tests/typecheck_typeshed.py | 2 +- 8 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/daily.yml b/.github/workflows/daily.yml index 58d85ed3fefb..516e6a2633b9 100644 --- a/.github/workflows/daily.yml +++ b/.github/workflows/daily.yml @@ -35,7 +35,7 @@ jobs: strategy: matrix: os: ["ubuntu-latest", "windows-latest", "macos-latest"] - python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] + python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] fail-fast: false steps: diff --git a/.github/workflows/meta_tests.yml b/.github/workflows/meta_tests.yml index 6acd88a39d42..af2711512728 100644 --- a/.github/workflows/meta_tests.yml +++ b/.github/workflows/meta_tests.yml @@ -65,7 +65,7 @@ jobs: with: version: PATH python-platform: ${{ matrix.python-platform }} - python-version: "3.9" # Oldest version supported for running scripts and tests + python-version: "3.10" # Oldest version supported for running scripts and tests project: ./pyrightconfig.scripts_and_tests.json stubsabot-dry-run: name: Stubsabot dry run diff --git a/.github/workflows/stubtest_stdlib.yml b/.github/workflows/stubtest_stdlib.yml index fd7c6cdebcb1..db679c9971cd 100644 --- a/.github/workflows/stubtest_stdlib.yml +++ b/.github/workflows/stubtest_stdlib.yml @@ -31,7 +31,7 @@ jobs: strategy: matrix: os: ["ubuntu-latest", "windows-latest", "macos-latest"] - python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] + python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] fail-fast: false steps: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6c93c9a84ee2..f00b63ab0db0 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -42,7 +42,7 @@ jobs: strategy: matrix: platform: ["linux", "win32", "darwin"] - python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] + python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] fail-fast: false steps: - uses: actions/checkout@v6 @@ -84,7 +84,7 @@ jobs: strategy: matrix: python-platform: ["Linux", "Windows", "Darwin"] - python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] + python-version: ["3.11", "3.12", "3.13", "3.14"] fail-fast: false steps: - uses: actions/checkout@v6 diff --git a/tests/mypy_test.py b/tests/mypy_test.py index 5e263a9cbb15..dfc7adba8062 100755 --- a/tests/mypy_test.py +++ b/tests/mypy_test.py @@ -44,7 +44,7 @@ print_error("Cannot import mypy. Did you install it?") sys.exit(1) -SUPPORTED_VERSIONS = ["3.14", "3.13", "3.12", "3.11", "3.10", "3.9"] +SUPPORTED_VERSIONS = ["3.14", "3.13", "3.12", "3.11", "3.10"] SUPPORTED_PLATFORMS = ("linux", "win32", "darwin") DIRECTORIES_TO_TEST = [STDLIB_PATH, STUBS_PATH] diff --git a/tests/regr_test.py b/tests/regr_test.py index 0693974a901f..b37509ad9f83 100755 --- a/tests/regr_test.py +++ b/tests/regr_test.py @@ -41,7 +41,7 @@ TYPESHED = "typeshed" SUPPORTED_PLATFORMS = ["linux", "darwin", "win32"] -SUPPORTED_VERSIONS = ["3.14", "3.13", "3.12", "3.11", "3.10", "3.9"] +SUPPORTED_VERSIONS = ["3.14", "3.13", "3.12", "3.11", "3.10"] def distribution_with_test_cases(distribution_name: str) -> DistributionTests: diff --git a/tests/runtests.py b/tests/runtests.py index 296cb8ccd068..832ade5216ba 100755 --- a/tests/runtests.py +++ b/tests/runtests.py @@ -50,7 +50,7 @@ def main() -> None: parser.add_argument( "--python-version", default=None, - choices=("3.9", "3.10", "3.11", "3.12", "3.13", "3.14"), + choices=("3.10", "3.11", "3.12", "3.13", "3.14"), # We're using the oldest fully supported version because it's the most likely to produce errors # due to unsupported syntax, feature, or bug in a tool. help="Target Python version for the test (defaults to oldest supported Python version).", diff --git a/tests/typecheck_typeshed.py b/tests/typecheck_typeshed.py index 90d7afcaf706..63449e4d4ee3 100755 --- a/tests/typecheck_typeshed.py +++ b/tests/typecheck_typeshed.py @@ -14,7 +14,7 @@ ReturnCode: TypeAlias = int SUPPORTED_PLATFORMS = ("linux", "darwin", "win32") -SUPPORTED_VERSIONS = ("3.14", "3.13", "3.12", "3.11", "3.10", "3.9") +SUPPORTED_VERSIONS = ("3.14", "3.13", "3.12", "3.11", "3.10") LOWEST_SUPPORTED_VERSION = min(SUPPORTED_VERSIONS, key=lambda x: int(x.split(".")[1])) DIRECTORIES_TO_TEST = ("scripts", "tests") EMPTY: list[str] = []