From 404c63b48c5d8ae5c8074db1d0f9b5df044df755 Mon Sep 17 00:00:00 2001 From: Diego Ramirez Date: Fri, 13 Oct 2023 15:15:34 -0600 Subject: [PATCH] Include Python 3.12 in GHA (#743) * Include Python 3.12 in Nox's action Add Python 3.12 to our supported pythons, as 3.12 is now stable. * Include Python 3.12 in our CI checks * Include Python 3.12 in our noxfile * Formatting fix on the noxfile A quick linting fix. --- .github/workflows/ci.yml | 2 +- action.yml | 4 ++-- noxfile.py | 14 ++++++++++++-- 3 files changed, 15 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9d2476ec..06d324f8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,7 +17,7 @@ jobs: strategy: matrix: os: [ubuntu-20.04, windows-latest, macos-latest] - python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"] + python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"] steps: - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} diff --git a/action.yml b/action.yml index cfac6c90..6b230160 100644 --- a/action.yml +++ b/action.yml @@ -4,7 +4,7 @@ inputs: python-versions: description: "comma-separated list of python versions to install" required: false - default: "3.7, 3.8, 3.9, 3.10, 3.11, pypy-3.7, pypy-3.8, pypy-3.9" + default: "3.7, 3.8, 3.9, 3.10, 3.11, 3.12, pypy-3.7, pypy-3.8, pypy-3.9" branding: icon: package color: blue @@ -15,7 +15,7 @@ runs: - uses: actions/setup-python@v4 id: localpython with: - python-version: "3.7 - 3.11" + python-version: "3.7 - 3.12" update-environment: false - name: "Validate input" diff --git a/noxfile.py b/noxfile.py index 3d2a65e8..93914d83 100644 --- a/noxfile.py +++ b/noxfile.py @@ -31,7 +31,7 @@ nox.options.sessions.append("conda_tests") -@nox.session(python=["3.7", "3.8", "3.9", "3.10", "3.11"]) +@nox.session(python=["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]) def tests(session: nox.Session) -> None: """Run test suite with pytest.""" session.create_tmp() # Fixes permission errors on Windows @@ -133,7 +133,17 @@ def _check_python_version(session: nox.Session) -> None: @nox.session( - python=["3.7", "3.8", "3.9", "3.10", "3.11", "pypy3.7", "pypy3.8", "pypy3.9"] + python=[ + "3.7", + "3.8", + "3.9", + "3.10", + "3.11", + "3.12", + "pypy3.7", + "pypy3.8", + "pypy3.9", + ] ) def github_actions_default_tests(session: nox.Session) -> None: """Check default versions installed by the nox GHA Action"""