Skip to content

Commit

Permalink
Add python 3.12 support (#83)
Browse files Browse the repository at this point in the history
* Update changelog.rst

* Update README.md

* Update release.yml

* Update tests.yml

* Update nox-session.yml

* Update noxfile.py

* Update tests.yml

* Update pyproject.toml

* Update .github/workflows/tests.yml

Co-authored-by: cqc-melf <[email protected]>

---------

Co-authored-by: cqc-melf <[email protected]>
  • Loading branch information
sjdilkes and cqc-melf authored Jan 23, 2024
1 parent aefa1b0 commit b4d5abe
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 10 deletions.
1 change: 1 addition & 0 deletions .github/workflows/nox-session.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ on:
options:
- "3.10"
- "3.11"
- "3.12"
os:
description: "Runner OS"
type: choice
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ on:
- cron: "0 4 * * 2"

env:
PYTHON_VERSION: "3.10"
PYTHON_VERSION: "3.11"

jobs:
build:
Expand All @@ -31,7 +31,7 @@ jobs:
with:
fetch-depth: "0"
- run: git fetch --depth=1 origin +refs/tags/*:refs/tags/* +refs/heads/*:refs/remotes/origin/*
- name: Set up Python 3.10
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: ${{ env.PYTHON_VERSION }}
Expand Down
16 changes: 12 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,19 @@ jobs:
fail-fast: false
matrix:
include:
- { python: "3.10", os: "ubuntu-22.04", session: "pre-commit" }
- { python: "3.10", os: "macos-12", session: "mypy" }
- { python: "3.11", os: "ubuntu-22.04", session: "pre-commit" }
- { python: "3.10", os: "ubuntu-22.04", session: "tests" }
- { python: "3.10", os: "macos-12", session: "tests" }
- { python: "3.11", os: "macos-12", session: "mypy" }
- { python: "3.10", os: "windows-2022", session: "tests" }
- { python: "3.10", os: "macos-12", session: "tests" }
- { python: "3.11", os: "windows-2022", session: "tests" }
- { python: "3.11", os: "ubuntu-22.04", session: "tests" }
- { python: "3.11", os: "macos-12", session: "tests" }
- { python: "3.10", os: "ubuntu-22.04", session: "docs-build" }
- { python: "3.12", os: "windows-2022", session: "tests" }
- { python: "3.12", os: "ubuntu-22.04", session: "tests" }
- { python: "3.12", os: "macos-12", session: "tests" }
- { python: "3.11", os: "ubuntu-22.04", session: "docs-build" }
uses: ./.github/workflows/nox-session.yml
with:
python-version: ${{ matrix.python }}
Expand All @@ -43,7 +48,7 @@ jobs:
fail-fast: false
matrix:
include:
- { python: "3.10", os: "ubuntu-22.04", session: "tests" }
- { python: "3.11", os: "ubuntu-22.04", session: "tests" }
uses: ./.github/workflows/nox-session.yml
with:
python-version: ${{ matrix.python }}
Expand Down Expand Up @@ -91,6 +96,9 @@ jobs:
- { python: "3.11", os: "windows-2022", session: "tests" }
- { python: "3.11", os: "ubuntu-22.04", session: "tests" }
- { python: "3.11", os: "macos-12", session: "tests" }
- { python: "3.12", os: "windows-2022", session: "tests" }
- { python: "3.12", os: "ubuntu-22.04", session: "tests" }
- { python: "3.12", os: "macos-12", session: "tests" }
uses: ./.github/workflows/nox-session.yml
with:
python-version: ${{ matrix.python }}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ See [extension documentation](https://cqcl.github.io/pytket-aqt/api/index.html)

## Getting started

`pytket-aqt` is available for Python 3.10 and 3.11, on Linux, MacOS
`pytket-aqt` is available for Python 3.10, 3.11 and 3.12, on Linux, MacOS
and Windows. To install, run:

```shell
Expand Down
8 changes: 8 additions & 0 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
Changelog
~~~~~~~~~

Unreleased
----------

General:

* Python 3.12 support added, 3.9 dropped.
* pytket dependency updated to 1.24

0.31.0 (January 2024)
---------------------

Expand Down
2 changes: 1 addition & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import nox

package = "pytket_aqt"
python_versions = ["3.11", "3.10"]
python_versions = ["3.12", "3.11", "3.10"]
nox.needs_version = ">= 2021.10.1"
nox.options.sessions = (
"pre-commit",
Expand Down
5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ classifiers= [
"Environment :: Console",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"License :: OSI Approved :: Apache Software License",
"Operating System :: MacOS :: MacOS X",
"Operating System :: POSIX :: Linux",
Expand All @@ -25,8 +26,8 @@ classifiers= [
"Bug Tracker" = "https://github.com/CQCL/pytket-aqt/issues"

[tool.poetry.dependencies]
python = ">=3.10, <3.12"
pytket = "^1.23"
python = ">=3.10"
pytket = "^1.24"
requests = "^2.22"
types-requests = "*"
pydantic = "^2.0"
Expand Down

0 comments on commit b4d5abe

Please sign in to comment.