Skip to content

Commit

Permalink
Update python support to 3.10, 3.11 and 3.12 (#243)
Browse files Browse the repository at this point in the history
* Update setup.py

* Update changelog.rst

* Update README.md

* Update intro.txt

* Update mypy.ini

* Update ecosystem.json

* Update build_and_test.yml

* Update setup.py

* Update changelog.rst

* Update build_and_test.yml

* Update docs.yml

* Update setup.py

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

* Update README.md

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

---------

Co-authored-by: cqc-melf <[email protected]>
  • Loading branch information
sjdilkes and cqc-melf authored Jan 17, 2024
1 parent c4c7fd3 commit 3ea0f5a
Show file tree
Hide file tree
Showing 8 changed files with 30 additions and 21 deletions.
24 changes: 12 additions & 12 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,38 +33,38 @@ 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.9
- name: Set up Python 3.10
if: github.event_name == 'push' || github.event_name == 'schedule'
uses: actions/setup-python@v5
with:
python-version: '3.9'
- name: Build and test (3.9)
python-version: '3.10'
- name: Build and test (3.10)
if: github.event_name == 'push' || github.event_name == 'schedule'
shell: bash
run: |
./.github/workflows/build-test nomypy
- name: Set up Python 3.10
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Build and test including remote checks (3.10) mypy
python-version: '3.11'
- name: Build and test including remote checks (3.11) mypy
if: (matrix.os == 'ubuntu-22.04') && (github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'release' || github.event_name == 'schedule' )
shell: bash
run: |
./.github/workflows/build-test mypy
env:
PYTKET_RUN_REMOTE_TESTS: 1
- name: Build and test (3.10) nomypy
- name: Build and test (3.11) nomypy
if: (matrix.os != 'macos-12') && (github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'release' || github.event_name == 'schedule')
shell: bash
run: |
./.github/workflows/build-test nomypy
- name: Set up Python 3.11
- name: Set up Python 3.12
if: github.event_name == 'push' || github.event_name == 'pull_request' || github.event_name == 'schedule'
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Build and test (3.11)
python-version: '3.12'
- name: Build and test (3.12)
if: github.event_name == 'push' || github.event_name == 'pull_request' || github.event_name == 'schedule'
shell: bash
run: |
Expand Down Expand Up @@ -119,10 +119,10 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Set up Python 3.10
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: '3.10'
python-version: '3.11'
- name: Download all wheels
uses: actions/download-artifact@v4
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: '3.10'
python-version: '3.11'
- name: Upgrade pip and install wheel
run: pip install --upgrade pip wheel
- name: Install pytket qiskit
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ representations.

## Getting started

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

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

Unreleased
----------

General:

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


0.47.0 (January 2024)
---------------------

Expand Down
2 changes: 1 addition & 1 deletion docs/intro.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ representations, simulation and access to the `IBMQ <https://www.research.ibm.co
run on IBM backends and simulators, as well as conversion to and from Qiskit
representations.

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

::
Expand Down
2 changes: 1 addition & 1 deletion ecosystem.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
],
"language": {
"name": "python",
"versions": ["3.9"]
"versions": ["3.10"]
},
"tests_command": [
"/bin/bash -ec 'cd tests && pytest'"
Expand Down
2 changes: 1 addition & 1 deletion mypy.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[mypy]
python_version = 3.9
python_version = 3.10
warn_unused_configs = True

disallow_untyped_decorators = False
Expand Down
6 changes: 3 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
version=metadata["__extension_version__"],
author="TKET development team",
author_email="[email protected]",
python_requires=">=3.9",
python_requires=">=3.10",
project_urls={
"Documentation": "https://tket.quantinuum.com/extensions/pytket-qiskit/index.html",
"Source": "https://github.com/CQCL/pytket-qiskit",
Expand All @@ -44,7 +44,7 @@
packages=find_namespace_packages(include=["pytket.*"]),
include_package_data=True,
install_requires=[
"pytket ~= 1.23",
"pytket ~= 1.24",
"qiskit ~= 0.45.0",
"qiskit-algorithms ~= 0.2.1",
"qiskit-ibm-runtime ~= 0.17.0",
Expand All @@ -54,9 +54,9 @@
],
classifiers=[
"Environment :: Console",
"Programming Language :: Python :: 3.9",
"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 Down

0 comments on commit 3ea0f5a

Please sign in to comment.