From 2b7c408f339265f935387e14a572f5b02262d966 Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Wed, 16 Nov 2022 22:43:23 +0200 Subject: [PATCH 1/6] Add support for Python 3.11 --- .github/workflows/ci.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 518b8c3..e5dc55e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,13 +9,13 @@ jobs: strategy: fail-fast: false matrix: - python: ['3.7', '3.8', '3.9', '3.10'] + python: ['3.7', '3.8', '3.9', '3.10', '3.11'] steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Setup python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python }} cache: pip @@ -34,7 +34,7 @@ jobs: strategy: fail-fast: false matrix: - python: ['3.7', '3.8', '3.9', '3.10', '3.11-dev'] + python: ['3.7', '3.8', '3.9', '3.10', '3.11'] check_formatting: ['0'] extra_name: [''] include: @@ -43,16 +43,16 @@ jobs: extra_name: ', check formatting' steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Setup python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 if: "!endsWith(matrix.python, '-dev')" with: python-version: ${{ matrix.python }} cache: pip cache-dependency-path: test-requirements.txt - name: Setup python (dev) - uses: deadsnakes/action@v2.0.2 + uses: deadsnakes/action@v2.1.1 if: endsWith(matrix.python, '-dev') with: python-version: '${{ matrix.python }}' @@ -70,12 +70,12 @@ jobs: strategy: fail-fast: false matrix: - python: ['3.7', '3.8', '3.9', '3.10'] + python: ['3.7', '3.8', '3.9', '3.10', '3.11'] steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Setup python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python }} cache: pip From 6536f23c9689a76ff8e192f9b1c7d5497c99fcaf Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Sun, 10 Sep 2023 18:43:28 +0300 Subject: [PATCH 2/6] Bump GitHub Actions --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e5dc55e..caa4864 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,7 +13,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup python uses: actions/setup-python@v4 with: @@ -43,7 +43,7 @@ jobs: extra_name: ', check formatting' steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup python uses: actions/setup-python@v4 if: "!endsWith(matrix.python, '-dev')" @@ -52,7 +52,7 @@ jobs: cache: pip cache-dependency-path: test-requirements.txt - name: Setup python (dev) - uses: deadsnakes/action@v2.1.1 + uses: deadsnakes/action@v3.0.1 if: endsWith(matrix.python, '-dev') with: python-version: '${{ matrix.python }}' @@ -73,7 +73,7 @@ jobs: python: ['3.7', '3.8', '3.9', '3.10', '3.11'] steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup python uses: actions/setup-python@v4 with: From d0c6b59b0ec132f55ec2d4ac108cfd3d9c56d620 Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Sun, 10 Sep 2023 20:26:22 +0300 Subject: [PATCH 3/6] Add support for Python 3.12 --- .github/workflows/ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index caa4864..298e320 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,7 +9,7 @@ jobs: strategy: fail-fast: false matrix: - python: ['3.7', '3.8', '3.9', '3.10', '3.11'] + python: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12'] steps: - name: Checkout @@ -18,6 +18,7 @@ jobs: uses: actions/setup-python@v4 with: python-version: ${{ matrix.python }} + allow-prereleases: true cache: pip cache-dependency-path: test-requirements.txt - name: Run tests @@ -34,7 +35,7 @@ jobs: strategy: fail-fast: false matrix: - python: ['3.7', '3.8', '3.9', '3.10', '3.11'] + python: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12-dev'] check_formatting: ['0'] extra_name: [''] include: From e29025f89c3d6c447c391adb0b782560000a99a9 Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Mon, 11 Sep 2023 12:58:23 +0300 Subject: [PATCH 4/6] Skip failing curio on Python 3.12+ --- sniffio/_tests/test_sniffio.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sniffio/_tests/test_sniffio.py b/sniffio/_tests/test_sniffio.py index 984c8c0..4c66082 100644 --- a/sniffio/_tests/test_sniffio.py +++ b/sniffio/_tests/test_sniffio.py @@ -63,6 +63,11 @@ async def this_is_asyncio(): os.name == "nt" and sys.version_info >= (3, 9), reason="Curio breaks on Python 3.9+ on Windows. Fix was not released yet", ) +@pytest.mark.skipif( + sys.version_info >= (3, 12), + reason= + "curio broken on 3.12 (https://github.com/python-trio/sniffio/pull/42)", +) def test_curio(): import curio From 6d813c9e9a0335b31a11e3069902e09670b7f2f8 Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Mon, 11 Sep 2023 12:59:19 +0300 Subject: [PATCH 5/6] Re-enable Windows/3.9+ after release of fix --- sniffio/_tests/test_sniffio.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/sniffio/_tests/test_sniffio.py b/sniffio/_tests/test_sniffio.py index 4c66082..02945a9 100644 --- a/sniffio/_tests/test_sniffio.py +++ b/sniffio/_tests/test_sniffio.py @@ -58,11 +58,6 @@ async def this_is_asyncio(): current_async_library() -# https://github.com/dabeaz/curio/pull/354 -@pytest.mark.skipif( - os.name == "nt" and sys.version_info >= (3, 9), - reason="Curio breaks on Python 3.9+ on Windows. Fix was not released yet", -) @pytest.mark.skipif( sys.version_info >= (3, 12), reason= From d44c25b62bd8d4173a7934352404d8386e50a38a Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Mon, 11 Sep 2023 13:04:42 +0300 Subject: [PATCH 6/6] Test 3.12 on macOS --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 298e320..33a0328 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -71,7 +71,7 @@ jobs: strategy: fail-fast: false matrix: - python: ['3.7', '3.8', '3.9', '3.10', '3.11'] + python: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12'] steps: - name: Checkout uses: actions/checkout@v4 @@ -79,6 +79,7 @@ jobs: uses: actions/setup-python@v4 with: python-version: ${{ matrix.python }} + allow-prereleases: true cache: pip cache-dependency-path: test-requirements.txt - name: Run tests