Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable the generation of wheels for python 3.11 and upgrade python on CI/CD workflows to 3.8 #381

Merged
merged 18 commits into from
Nov 2, 2022
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Install dependencies
run: sudo apt-get update && sudo apt-get -y -q install cmake gcc-10 g++-10 ninja-build libopenblas-dev
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.7
python-version: 3.8

- name: Install dependencies
run:
Expand Down Expand Up @@ -77,7 +77,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.7'
python-version: '3.8'

- name: Restoring cached dependencies
id: kokkos-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/post_release_version_bump.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
uses: actions/checkout@v3

- name: Install Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.9'

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pre_release_version_bump.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
uses: actions/checkout@v3

- name: Install Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.9'

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/set_wheel_build_matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Set wheel build matrix

env:
PYTHON3_MIN_VERSION: "7"
PYTHON3_MAX_VERSION: "10"
PYTHON3_MAX_VERSION: "11"

on:
workflow_call:
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/tests_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Checkout PennyLane-Lightning
uses: actions/checkout@v3
Expand Down Expand Up @@ -89,7 +89,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Install dependencies
run: sudo apt-get update && sudo apt-get -y -q install cmake gcc-11 g++-11
Expand Down Expand Up @@ -143,7 +143,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Checkout PennyLane-Lightning
uses: actions/checkout@v3
Expand Down Expand Up @@ -207,7 +207,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Install dependencies
run: sudo apt-get update && sudo apt-get -y -q install cmake gcc-11 g++-11 libopenblas-dev
Expand Down Expand Up @@ -270,7 +270,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Checkout PennyLane-Lightning
uses: actions/checkout@v3
Expand Down Expand Up @@ -349,7 +349,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Restoring cached dependencies
id: kokkos-cache
Expand Down Expand Up @@ -419,7 +419,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Checkout PennyLane-Lightning
uses: actions/checkout@v3
Expand Down Expand Up @@ -498,7 +498,7 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Restoring cached dependencies
id: kokkos-cache
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/tests_without_binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ jobs:
with:
path: main

- uses: actions/setup-python@v2
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Get required Python packages
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/update_dev_version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:
ref: master
path: main

- uses: actions/setup-python@v2
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Checkout PennyLane-Lightning PR
uses: actions/checkout@v3
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/wheel_linux_aarch64.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
name: Wheel::Linux::ARM

# **What it does**: Builds python wheels for Linux (ubuntu-latest) architecture ARM 64 and store it as artifacts.
# Python versions: 3.7, 3.8, 3.9, 3.10.
# Python versions: 3.7, 3.8, 3.9, 3.10, 3.11.
# **Why we have it**: To build wheels for pennylane-lightning installation.
# **Who does it impact**: Wheels to be uploaded to PyPI.

on:
pull_request:
AmintorDusko marked this conversation as resolved.
Show resolved Hide resolved
push:
branches:
- master
Expand Down Expand Up @@ -72,8 +73,8 @@ jobs:
-v ${{ github.workspace }}/Kokkos_install/${{ matrix.exec_model }}:/install \
-i ${{ matrix.container_img }} \
bash -c "cd /io && \
python3.7 -m pip install ninja && \
ln -s /opt/python/cp37-cp37m/bin/ninja /usr/bin/ninja && \
python3.8 -m pip install ninja && \
ln -s /opt/python/cp38-cp38m/bin/ninja /usr/bin/ninja && \
cmake -BBuild . -DCMAKE_INSTALL_PREFIX=/install \
-DKokkos_ENABLE_COMPLEX_ALIGN=OFF \
-DKokkos_ENABLE_${{ matrix.exec_model }}=ON \
Expand All @@ -94,8 +95,8 @@ jobs:
-v ${{ github.workspace }}/Kokkos_install/${{ matrix.exec_model }}:/install \
-i ${{ matrix.container_img }} \
bash -c "cd /io && \
python3.7 -m pip install ninja && \
ln -s /opt/python/cp37-cp37m/bin/ninja /usr/bin/ninja && \
python3.8 -m pip install ninja && \
ln -s /opt/python/cp38-cp38m/bin/ninja /usr/bin/ninja && \
cmake -BBuild . -DCMAKE_INSTALL_PREFIX=/install \
-DKokkos_ENABLE_${{ matrix.exec_model }}=ON \
-DKokkos_ENABLE_DEPRECATION_WARNINGS=OFF \
Expand All @@ -119,7 +120,7 @@ jobs:
kokkos_version: ${{ fromJson(needs.set_wheel_build_matrix.outputs.kokkos_version) }}
container_img: ["quay.io/pypa/manylinux2014_aarch64"]

name: ubuntu-latest::aarch64 (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10" }')[matrix.cibw_build] }})
name: ubuntu-latest::aarch64 (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10","cp311-*":"3.11" }')[matrix.cibw_build] }})
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -143,7 +144,7 @@ jobs:
cp -rf ${{ github.workspace }}/Kokkos_install/${{ matrix.exec_model }}/* Kokkos/

- name: Install cibuildwheel
run: python3 -m pip install cibuildwheel==2.8.1
run: python3 -m pip install cibuildwheel~=2.11.0

- uses: docker/setup-qemu-action@v2
name: Set up QEMU
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/wheel_linux_ppc64le.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
name: Wheel::Linux::PowerPC

# **What it does**: Builds python wheels for Linux (ubuntu-latest) architecture PowerPC 64 and store it as artifacts.
# Python versions: 3.7, 3.8, 3.9, 3.10.
# Python versions: 3.7, 3.8, 3.9, 3.10, 3.11.
# **Why we have it**: To build wheels for pennylane-lightning installation.
# **Who does it impact**: Wheels to be uploaded to PyPI.

on:
pull_request:
AmintorDusko marked this conversation as resolved.
Show resolved Hide resolved
push:
branches:
- master
Expand Down Expand Up @@ -72,8 +73,8 @@ jobs:
-v ${{ github.workspace }}/Kokkos_install/${{ matrix.exec_model }}:/install \
-i ${{ matrix.container_img }} \
bash -c "cd /io && \
python3.7 -m pip install ninja && \
ln -s /opt/python/cp37-cp37m/bin/ninja /usr/bin/ninja && \
python3.8 -m pip install ninja && \
ln -s /opt/python/cp38-cp38m/bin/ninja /usr/bin/ninja && \
cmake -BBuild . -DCMAKE_INSTALL_PREFIX=/install \
-DKokkos_ENABLE_COMPLEX_ALIGN=OFF \
-DKokkos_ENABLE_${{ matrix.exec_model }}=ON \
Expand All @@ -94,8 +95,8 @@ jobs:
-v ${{ github.workspace }}/Kokkos_install/${{ matrix.exec_model }}:/install \
-i ${{ matrix.container_img }} \
bash -c "cd /io && \
python3.7 -m pip install ninja && \
ln -s /opt/python/cp37-cp37m/bin/ninja /usr/bin/ninja && \
python3.8 -m pip install ninja && \
ln -s /opt/python/cp38-cp38m/bin/ninja /usr/bin/ninja && \
cmake -BBuild . -DCMAKE_INSTALL_PREFIX=/install \
-DKokkos_ENABLE_${{ matrix.exec_model }}=ON \
-DKokkos_ENABLE_DEPRECATION_WARNINGS=OFF \
Expand All @@ -119,7 +120,7 @@ jobs:
kokkos_version: ${{ fromJson(needs.set_wheel_build_matrix.outputs.kokkos_version) }}
container_img: ["quay.io/pypa/manylinux2014_ppc64le"]

name: ubuntu-latest::ppc64le (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10" }')[matrix.cibw_build] }})
name: ubuntu-latest::ppc64le (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10","cp311-*":"3.11" }')[matrix.cibw_build] }})
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -143,7 +144,7 @@ jobs:
cp -rf ${{ github.workspace }}/Kokkos_install/${{ matrix.exec_model }}/* Kokkos/

- name: Install cibuildwheel
run: python3 -m pip install cibuildwheel==2.8.1
run: python3 -m pip install cibuildwheel~=2.11.0

- uses: docker/setup-qemu-action@v2
name: Set up QEMU
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/wheel_linux_x86_64.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Wheel::Linux::x86_64

# **What it does**: Builds python wheels for Linux (ubuntu-latest) architecture x86_64 and store it as artifacts.
# Python versions: 3.7, 3.8, 3.9, 3.10.
# Python versions: 3.7, 3.8, 3.9, 3.10, 3.11.
# **Why we have it**: To build wheels for pennylane-lightning installation.
# **Who does it impact**: Wheels to be uploaded to PyPI.

Expand Down Expand Up @@ -115,7 +115,7 @@ jobs:
kokkos_version: ${{ fromJson(needs.set_wheel_build_matrix.outputs.kokkos_version) }}
container_img: ["quay.io/pypa/manylinux2014_x86_64"]

name: ${{ matrix.os }} (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10" }')[matrix.cibw_build] }})
name: ${{ matrix.os }} (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10","cp311-*":"3.11" }')[matrix.cibw_build] }})
runs-on: ${{ matrix.os }}
container: ${{ matrix.container_img }}

Expand Down Expand Up @@ -148,7 +148,7 @@ jobs:
yum update -y && yum install -y docker

- name: Install cibuildwheel
run: python3.7 -m pip install cibuildwheel==2.8.1
run: python3.8 -m pip install cibuildwheel~=2.11.0

- name: Build wheels
env:
Expand Down Expand Up @@ -181,7 +181,7 @@ jobs:

CIBW_BUILD_VERBOSITY: 3

run: python3.7 -m cibuildwheel --output-dir wheelhouse
run: python3.8 -m cibuildwheel --output-dir wheelhouse

- uses: actions-ecosystem/action-regex-match@v2
id: rc_build
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/wheel_macos_arm64.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Wheel::MacOS::ARM

# **What it does**: Builds python wheels for MacOS (11) architecture ARM 64 and store it as artifacts.
# Python versions: 3.8, 3.9, 3.10.
# Python versions: 3.8, 3.9, 3.10, 3.11.
# **Why we have it**: To build wheels for pennylane-lightning installation.
# **Who does it impact**: Wheels to be uploaded to PyPI.

Expand All @@ -16,7 +16,7 @@ on:
env:
ARCHS: 'arm64'
PYTHON3_MIN_VERSION: "8"
PYTHON3_MAX_VERSION: "10"
PYTHON3_MAX_VERSION: "11"

jobs:
mac-set-matrix-arm:
Expand Down Expand Up @@ -58,7 +58,7 @@ jobs:
arch: [arm64]
cibw_build: ${{fromJson(needs.mac-set-matrix-arm.outputs.python_version)}}

name: macos-latest::arm64 (Python ${{ fromJson('{ "cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10" }')[matrix.cibw_build] }})
name: macos-latest::arm64 (Python ${{ fromJson('{ "cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10","cp311-*":"3.11" }')[matrix.cibw_build] }})
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -70,13 +70,13 @@ jobs:
- name: Checkout PennyLane-Lightning
uses: actions/checkout@v3

- uses: actions/setup-python@v2
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.8'

- name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.8.1
run: python -m pip install cibuildwheel~=2.11.0

- name: Build wheels
env:
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/wheel_macos_x86_64.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Wheel::MacOS::Intel

# **What it does**: Builds python wheels for MacOS (10.15) architecture x86_64 and store it as artifacts.
# Python versions: 3.7, 3.8, 3.9, 3.10.
# Python versions: 3.7, 3.8, 3.9, 3.10, 3.11.
# **Why we have it**: To build wheels for pennylane-lightning installation.
# **Who does it impact**: Wheels to be uploaded to PyPI.

Expand Down Expand Up @@ -64,10 +64,10 @@ jobs:
git checkout ${{ matrix.kokkos_version }}
cd -

- uses: actions/setup-python@v2
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Build Kokkos core library
if: steps.kokkos-cache.outputs.cache-hit != 'true'
Expand Down Expand Up @@ -117,7 +117,7 @@ jobs:
exec_model: ${{ fromJson(needs.set_wheel_build_matrix.outputs.exec_model) }}
kokkos_version: ${{ fromJson(needs.set_wheel_build_matrix.outputs.kokkos_version) }}

name: ${{ matrix.os }} (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10" }')[matrix.cibw_build] }})
name: ${{ matrix.os }} (Python ${{ fromJson('{ "cp37-*":"3.7","cp38-*":"3.8","cp39-*":"3.9","cp310-*":"3.10","cp311-*":"3.11" }')[matrix.cibw_build] }})
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -140,13 +140,13 @@ jobs:
mkdir Kokkos
cp -rf ${{ github.workspace }}/Kokkos_install/${{ matrix.exec_model }}/* Kokkos/

- uses: actions/setup-python@v2
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
python-version: '3.8'

- name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.8.1
run: python -m pip install cibuildwheel~=2.11.0

- name: Build wheels
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/wheel_noarch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
with:
path: main

- uses: actions/setup-python@v2
- uses: actions/setup-python@v4
with:
python-version: '3.7'

Expand Down
Loading