From a86febd828fdedb49f2e87394a41df15eac0d22f Mon Sep 17 00:00:00 2001 From: Jun Doi Date: Thu, 25 Apr 2024 10:45:11 +0900 Subject: [PATCH 1/6] upgrade github actions for macos_arm64 and windows --- .github/workflows/build.yml | 28 +++++++++++++++------------- .github/workflows/deploy.yml | 24 +++++++++++++----------- .github/workflows/docs-publish.yml | 2 +- .github/workflows/docs.yml | 4 ++-- .github/workflows/tests.yml | 10 +++++----- pyproject.toml | 2 +- 6 files changed, 37 insertions(+), 33 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ab888efe79..6109d1c1f7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -12,13 +12,13 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: ["macOS-latest", "ubuntu-latest", "windows-2019"] + os: ["macos-13", "ubuntu-latest", "windows-latest"] steps: - uses: actions/checkout@v4 - - name: Set up Python 3.8 + - name: Set up Python '3.10' uses: actions/setup-python@v5 with: - python-version: 3.8 + python-version: '3.10' - name: Install deps run: pip install "conan<2.0.0" - name: Install openblas @@ -74,10 +74,10 @@ jobs: os: ["ubuntu-latest"] steps: - uses: actions/checkout@v4 - - name: Set up Python 3.8 + - name: Set up Python '3.10' uses: actions/setup-python@v5 with: - python-version: 3.8 + python-version: '3.10' - name: Install deps run: pip install "conan<2.0.0" - name: Install openblas and mpi @@ -121,13 +121,13 @@ jobs: needs: ["standalone"] strategy: matrix: - os: ["macOS-latest", "ubuntu-latest", "windows-2019"] + os: ["macos-13", "ubuntu-latest", "windows-latest"] steps: - uses: actions/checkout@v4 - - name: Set up Python Python 3.8 + - name: Set up Python Python '3.10' uses: actions/setup-python@v5 with: - python-version: 3.8 + python-version: '3.10' - name: Add msbuild to PATH uses: microsoft/setup-msbuild@v2 if: runner.os == 'Windows' @@ -136,6 +136,7 @@ jobs: - name: Build Wheels env: AER_CMAKE_OPENMP_BUILD: 1 + CIBW_TEST_SKIP: "cp38-macosx_arm64 cp39-macosx_arm64" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v4 with: @@ -145,18 +146,19 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: ["macOS-latest"] + os: ["macos-latest"] steps: - uses: actions/checkout@v4 - - name: Set up Python Python 3.8 + - name: Set up Python Python 3.10 uses: actions/setup-python@v5 with: - python-version: 3.8 + python-version: '3.10' - name: Install deps run: python -m pip install -U cibuildwheel==2.17.0 - name: Build Wheels env: CIBW_ARCHS_MACOS: arm64 + CIBW_SKIP: "cp38* cp39*" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v4 with: @@ -178,7 +180,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install cibuildwheel run: | python -m pip install cibuildwheel==2.17.0 @@ -211,7 +213,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install cibuildwheel run: | python -m pip install cibuildwheel==2.17.0 diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 6b8be200a2..2fb52f7f01 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -8,7 +8,7 @@ jobs: name: Build qiskit-aer wheels strategy: matrix: - os: ["macOS-latest", "ubuntu-latest", "windows-2019"] + os: ["macos-13", "ubuntu-latest", "windows-latest", "macos-latest"] runs-on: ${{ matrix.os }} environment: release steps: @@ -16,13 +16,14 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install cibuildwheel run: | python -m pip install cibuildwheel==2.17.0 - name: Build wheels env: AER_CMAKE_OPENMP_BUILD: 1 + CIBW_TEST_SKIP: "cp38-macosx_arm64 cp39-macosx_arm64" run: python -m cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v4 with: @@ -43,7 +44,7 @@ jobs: - uses: actions/setup-python@v4 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: actions-rs/toolchain@v1 with: toolchain: stable @@ -73,19 +74,20 @@ jobs: strategy: fail-fast: false matrix: - os: ["macOS-latest"] + os: ["macos-latest"] environment: release steps: - uses: actions/checkout@v4 - - name: Set up Python Python 3.8 + - name: Set up Python Python '3.10' uses: actions/setup-python@v5 with: - python-version: 3.8 + python-version: '3.10' - name: Install deps run: python -m pip install -U cibuildwheel==2.17.0 - name: Build Wheels env: CIBW_ARCHS_MACOS: arm64 + CIBW_SKIP: "cp38* cp39*" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v3 with: @@ -103,7 +105,7 @@ jobs: - uses: actions/setup-python@v4 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install Deps run: pip install -U scikit-build wheel - name: Build Artifacts @@ -140,7 +142,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install cibuildwheel run: | python -m pip install cibuildwheel==2.17.0 @@ -183,7 +185,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install cibuildwheel run: | python -m pip install cibuildwheel==2.17.0 @@ -218,7 +220,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: actions-rs/toolchain@v1 with: toolchain: stable @@ -254,7 +256,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: actions-rs/toolchain@v1 with: toolchain: stable diff --git a/.github/workflows/docs-publish.yml b/.github/workflows/docs-publish.yml index 441379784a..cb947a2c88 100644 --- a/.github/workflows/docs-publish.yml +++ b/.github/workflows/docs-publish.yml @@ -15,7 +15,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.8' + python-version: '3.10' - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 8156b42000..008a1dec36 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -13,7 +13,7 @@ jobs: timeout-minutes: 60 strategy: matrix: - python-version: [3.8] + python-version: ['3.10'] steps: - uses: actions/checkout@v4 with: @@ -50,7 +50,7 @@ jobs: needs: [docs] strategy: matrix: - python-version: [3.8] + python-version: ['3.10'] steps: - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 5a43ee85ed..e7326fd7cf 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.8] + python-version: ['3.10'] steps: - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} @@ -147,7 +147,7 @@ jobs: timeout-minutes: 60 strategy: matrix: - python-version: [3.9] + python-version: ['3.10'] os: ["ubuntu-latest"] env: AER_THRUST_BACKEND: OMP @@ -192,13 +192,13 @@ jobs: stestr run --slowest shell: bash tests_macos: - runs-on: macOS-latest + runs-on: macos-13 name: macOS Python ${{ matrix.python-version }} needs: [sdist, lint] timeout-minutes: 60 strategy: matrix: - python-version: [3.8, 3.9, "3.10", '3.11', "3.12.0"] + python-version: ["3.10", '3.11', "3.12.0"] env: AER_THRUST_BACKEND: OMP QISKIT_TEST_CAPTURE_STREAMS: 1 @@ -236,7 +236,7 @@ jobs: stestr run --slowest shell: bash tests_windows: - runs-on: windows-2019 + runs-on: windows-latest name: Windows Python ${{ matrix.python-version }} needs: ["lint", "sdist"] timeout-minutes: 60 diff --git a/pyproject.toml b/pyproject.toml index f6b8371875..b3c0cf01e3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,7 +12,7 @@ build-backend = "setuptools.build_meta" [tool.cibuildwheel] manylinux-x86_64-image = "manylinux2014" manylinux-i686-image = "manylinux2014" -skip = "pp* cp36* cp37* *musllinux*" +skip = "pp* cp36* cp37* *musllinux* cp38-macosx_arm64" test-skip = "cp3*-win32 cp3*-manylinux_i686" test-command = "python {project}/tools/verify_wheels.py" # We need to use pre-built versions of Numpy and Scipy in the tests; they have a From 2e8852ea46639152a722f393c13da35a4fbade23 Mon Sep 17 00:00:00 2001 From: Jun Doi Date: Thu, 25 Apr 2024 10:56:23 +0900 Subject: [PATCH 2/6] skip pp38/39 --- .github/workflows/build.yml | 2 +- .github/workflows/deploy.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6109d1c1f7..e4aa4d5483 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -158,7 +158,7 @@ jobs: - name: Build Wheels env: CIBW_ARCHS_MACOS: arm64 - CIBW_SKIP: "cp38* cp39*" + CIBW_SKIP: "*p38* *p39*" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v4 with: diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 2fb52f7f01..033349e2f7 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -87,7 +87,7 @@ jobs: - name: Build Wheels env: CIBW_ARCHS_MACOS: arm64 - CIBW_SKIP: "cp38* cp39*" + CIBW_SKIP: "*p38* *p39*" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v3 with: From 1920e1a471d96d2f8266e52bc5d94219a7cd7465 Mon Sep 17 00:00:00 2001 From: Jun Doi Date: Thu, 25 Apr 2024 12:11:37 +0900 Subject: [PATCH 3/6] exclude pp --- .github/workflows/build.yml | 5 +++-- .github/workflows/deploy.yml | 7 ++++--- .github/workflows/tests.yml | 2 +- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e4aa4d5483..854aad3b55 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -12,7 +12,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: ["macos-13", "ubuntu-latest", "windows-latest"] + os: ["macos-13", "ubuntu-latest", "windows-2019"] steps: - uses: actions/checkout@v4 - name: Set up Python '3.10' @@ -153,12 +153,13 @@ jobs: uses: actions/setup-python@v5 with: python-version: '3.10' + architecture: arm64 - name: Install deps run: python -m pip install -U cibuildwheel==2.17.0 - name: Build Wheels env: CIBW_ARCHS_MACOS: arm64 - CIBW_SKIP: "*p38* *p39*" + CIBW_SKIP: "pp* cp38* cp39*" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v4 with: diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 033349e2f7..474a762d47 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -8,7 +8,7 @@ jobs: name: Build qiskit-aer wheels strategy: matrix: - os: ["macos-13", "ubuntu-latest", "windows-latest", "macos-latest"] + os: ["macos-13", "ubuntu-latest", "windows-2019"] runs-on: ${{ matrix.os }} environment: release steps: @@ -23,7 +23,7 @@ jobs: - name: Build wheels env: AER_CMAKE_OPENMP_BUILD: 1 - CIBW_TEST_SKIP: "cp38-macosx_arm64 cp39-macosx_arm64" + CIBW_SKIP: "pp* cp38-macosx_arm64 cp39-macosx_arm64" run: python -m cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v4 with: @@ -82,12 +82,13 @@ jobs: uses: actions/setup-python@v5 with: python-version: '3.10' + architecture: arm64 - name: Install deps run: python -m pip install -U cibuildwheel==2.17.0 - name: Build Wheels env: CIBW_ARCHS_MACOS: arm64 - CIBW_SKIP: "*p38* *p39*" + CIBW_SKIP: "pp* cp38* cp39*" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v3 with: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e7326fd7cf..6c7a00a6b7 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -236,7 +236,7 @@ jobs: stestr run --slowest shell: bash tests_windows: - runs-on: windows-latest + runs-on: windows-2019 name: Windows Python ${{ matrix.python-version }} needs: ["lint", "sdist"] timeout-minutes: 60 From 83a7421ec169caeeb54a8d888f204e586c83ae11 Mon Sep 17 00:00:00 2001 From: Jun Doi Date: Thu, 25 Apr 2024 12:44:49 +0900 Subject: [PATCH 4/6] fix doc --- .github/workflows/docs-publish.yml | 2 +- .github/workflows/docs.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/docs-publish.yml b/.github/workflows/docs-publish.yml index cb947a2c88..441379784a 100644 --- a/.github/workflows/docs-publish.yml +++ b/.github/workflows/docs-publish.yml @@ -15,7 +15,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.10' + python-version: '3.8' - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 008a1dec36..074add47a9 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -13,7 +13,7 @@ jobs: timeout-minutes: 60 strategy: matrix: - python-version: ['3.10'] + python-version: ['3.8'] steps: - uses: actions/checkout@v4 with: @@ -50,7 +50,7 @@ jobs: needs: [docs] strategy: matrix: - python-version: ['3.10'] + python-version: ['3.8'] steps: - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} From cb9d7790e95b542b1c5164c5a35b6080ae542760 Mon Sep 17 00:00:00 2001 From: Jun Doi Date: Thu, 25 Apr 2024 13:25:40 +0900 Subject: [PATCH 5/6] test --- .github/workflows/build.yml | 2 +- .github/workflows/tests.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 854aad3b55..5ebf8b7faa 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -121,7 +121,7 @@ jobs: needs: ["standalone"] strategy: matrix: - os: ["macos-13", "ubuntu-latest", "windows-latest"] + os: ["macos-13", "ubuntu-latest", "windows-2019"] steps: - uses: actions/checkout@v4 - name: Set up Python Python '3.10' diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6c7a00a6b7..5f3e080453 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -198,7 +198,7 @@ jobs: timeout-minutes: 60 strategy: matrix: - python-version: ["3.10", '3.11', "3.12.0"] + python-version: [3.8, 3.9, "3.10", '3.11', "3.12.0"] env: AER_THRUST_BACKEND: OMP QISKIT_TEST_CAPTURE_STREAMS: 1 From 41903d833671025535cc6cd1634e4a26b35e39d7 Mon Sep 17 00:00:00 2001 From: Jun Doi Date: Thu, 25 Apr 2024 13:50:22 +0900 Subject: [PATCH 6/6] remove CIBW_TEST_SKIP for wheel --- .github/workflows/build.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5ebf8b7faa..8c1592f79b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -136,7 +136,6 @@ jobs: - name: Build Wheels env: AER_CMAKE_OPENMP_BUILD: 1 - CIBW_TEST_SKIP: "cp38-macosx_arm64 cp39-macosx_arm64" run: cibuildwheel --output-dir wheelhouse - uses: actions/upload-artifact@v4 with: