From a0a55403a7950c047238d5a4c3c3a6c6b317091e Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 12:41:23 +0200 Subject: [PATCH 1/9] =?UTF-8?q?=E2=9C=A8=20experimental=20C++=20downstream?= =?UTF-8?q?=20tests?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 71 +++++++++++++++++++ .github/workflows/reusable-cpp-ci.yml | 9 +++ .../workflows/reusable-cpp-tests-macos.yml | 7 ++ .../workflows/reusable-cpp-tests-ubuntu.yml | 7 ++ .../workflows/reusable-cpp-tests-windows.yml | 7 ++ 5 files changed, 101 insertions(+) create mode 100644 .github/workflows/downstream.yml diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml new file mode 100644 index 0000000..610fb8f --- /dev/null +++ b/.github/workflows/downstream.yml @@ -0,0 +1,71 @@ +# Copyright (c) 2023 - 2025 Chair for Design Automation, TUM +# Copyright (c) 2025 Munich Quantum Software Company GmbH +# All rights reserved. +# +# SPDX-License-Identifier: MIT +# +# Licensed under the MIT License + +name: Downstream Tests +on: + push: + branches: + - main + pull_request: + merge_group: + workflow_dispatch: + +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + +jobs: + cpp-downstream-test: + strategy: + matrix: + package: + - { user: munich-quantum-toolkit, repo: core, setup-z3: false } + - { user: cda-tum, repo: mqt-qcec, setup-z3: false } + - { user: cda-tum, repo: mqt-qmap, setup-z3: true } + - { user: cda-tum, repo: mqt-ddsim, setup-z3: false } + uses: .github/workflows/reusable-cpp-ci.yml + with: + repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} + setup-z3: ${{ matrix.package.setup-z3 }} + # enable running on all supported combinations + enable-ubuntu2404-gcc-release: true + enable-ubuntu2404-arm-gcc-release: true + enable-macos13-clang-release: true + enable-macos14-clang-release: true + enable-windows2022-msvc-release: true + enable-ubuntu2404-gcc-debug: true + enable-ubuntu2404-clang-release: true + enable-ubuntu2404-clang-debug: true + enable-ubuntu2204-gcc-release: true + enable-ubuntu2204-gcc-debug: true + enable-ubuntu2204-clang-release: true + enable-ubuntu2204-clang-debug: true + enable-ubuntu2404-arm-gcc-debug: true + enable-ubuntu2404-arm-clang-release: true + enable-ubuntu2404-arm-clang-debug: true + enable-ubuntu2204-arm-gcc-release: true + enable-ubuntu2204-arm-gcc-debug: true + enable-ubuntu2204-arm-clang-release: true + enable-ubuntu2204-arm-clang-debug: true + enable-macos13-clang-debug: true + enable-macos13-gcc-release: true + enable-macos13-gcc-debug: true + enable-macos14-clang-debug: true + enable-macos14-gcc-release: true + enable-macos14-gcc-debug: true + enable-macos15-clang-release: true + enable-macos15-clang-debug: true + enable-macos15-gcc-release: true + enable-macos15-gcc-debug: true + enable-windows2022-msvc-debug: true + enable-windows2022-clang-release: true + enable-windows2022-clang-debug: true + enable-windows2025-msvc-release: true + enable-windows2025-msvc-debug: true + enable-windows2025-clang-release: true + enable-windows2025-clang-debug: true diff --git a/.github/workflows/reusable-cpp-ci.yml b/.github/workflows/reusable-cpp-ci.yml index 08c6804..87183ae 100644 --- a/.github/workflows/reusable-cpp-ci.yml +++ b/.github/workflows/reusable-cpp-ci.yml @@ -11,6 +11,12 @@ on: workflow_call: inputs: ###---- General inputs ----------------------------------------------------------------------------------------### + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string cmake-args: description: > Additional arguments to pass to CMake on every OS. Defaults to an empty string. @@ -386,6 +392,7 @@ jobs: fail-fast: false uses: ./.github/workflows/reusable-cpp-tests-ubuntu.yml with: + repository: ${{ inputs.repository }} runs-on: ${{ matrix.runs-on }} compiler: ${{ matrix.compiler }} config: ${{ matrix.config }} @@ -403,6 +410,7 @@ jobs: fail-fast: false uses: ./.github/workflows/reusable-cpp-tests-macos.yml with: + repository: ${{ inputs.repository }} runs-on: ${{ matrix.runs-on }} compiler: ${{ matrix.compiler }} config: ${{ matrix.config }} @@ -420,6 +428,7 @@ jobs: fail-fast: false uses: ./.github/workflows/reusable-cpp-tests-windows.yml with: + repository: ${{ inputs.repository }} runs-on: ${{ matrix.runs-on }} compiler: ${{ matrix.compiler }} config: ${{ matrix.config }} diff --git a/.github/workflows/reusable-cpp-tests-macos.yml b/.github/workflows/reusable-cpp-tests-macos.yml index ac29875..29550a3 100644 --- a/.github/workflows/reusable-cpp-tests-macos.yml +++ b/.github/workflows/reusable-cpp-tests-macos.yml @@ -10,6 +10,12 @@ name: 🇨 • Tests • macos on: workflow_call: inputs: + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string runs-on: description: > The macOS runner image to use. Defaults to 'macos-latest'. @@ -57,6 +63,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # optionally set up Z3 diff --git a/.github/workflows/reusable-cpp-tests-ubuntu.yml b/.github/workflows/reusable-cpp-tests-ubuntu.yml index 53911ad..b709b98 100644 --- a/.github/workflows/reusable-cpp-tests-ubuntu.yml +++ b/.github/workflows/reusable-cpp-tests-ubuntu.yml @@ -10,6 +10,12 @@ name: 🇨 • Tests • ubuntu on: workflow_call: inputs: + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string runs-on: description: > The ubuntu runner image to use. Defaults to 'ubuntu-latest'. @@ -57,6 +63,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # optionally set up Z3 diff --git a/.github/workflows/reusable-cpp-tests-windows.yml b/.github/workflows/reusable-cpp-tests-windows.yml index 4414d4d..d411490 100644 --- a/.github/workflows/reusable-cpp-tests-windows.yml +++ b/.github/workflows/reusable-cpp-tests-windows.yml @@ -10,6 +10,12 @@ name: 🇨 • Tests • windows on: workflow_call: inputs: + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string runs-on: description: > The Windows runner image to use. Defaults to 'windows-latest'. @@ -60,6 +66,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # optionally set up Z3 From 7180fd3071657727a4145b0923d775f505e51859 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 12:46:03 +0200 Subject: [PATCH 2/9] =?UTF-8?q?=F0=9F=A9=B9=20use=20local=20workflow=20ref?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 610fb8f..90d8ee6 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -28,7 +28,7 @@ jobs: - { user: cda-tum, repo: mqt-qcec, setup-z3: false } - { user: cda-tum, repo: mqt-qmap, setup-z3: true } - { user: cda-tum, repo: mqt-ddsim, setup-z3: false } - uses: .github/workflows/reusable-cpp-ci.yml + uses: ./.github/workflows/reusable-cpp-ci.yml with: repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} setup-z3: ${{ matrix.package.setup-z3 }} From b14e123aca441cd85b74ffb10085b44692c0c7c3 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 12:47:17 +0200 Subject: [PATCH 3/9] =?UTF-8?q?=F0=9F=8E=A8=20proper=20workflow=20name?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 90d8ee6..8ff18c1 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -28,6 +28,7 @@ jobs: - { user: cda-tum, repo: mqt-qcec, setup-z3: false } - { user: cda-tum, repo: mqt-qmap, setup-z3: true } - { user: cda-tum, repo: mqt-ddsim, setup-z3: false } + name: 🇨‌ • CI • ${{ matrix.package.user }}/${{ matrix.package.repo }} uses: ./.github/workflows/reusable-cpp-ci.yml with: repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} From 787f385caa4845d75546c65f79bfb04d22e1c72b Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 12:50:55 +0200 Subject: [PATCH 4/9] =?UTF-8?q?=F0=9F=9B=82=20explicitly=20set=20workflow?= =?UTF-8?q?=20permissions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 8ff18c1..031fc5f 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -29,6 +29,8 @@ jobs: - { user: cda-tum, repo: mqt-qmap, setup-z3: true } - { user: cda-tum, repo: mqt-ddsim, setup-z3: false } name: 🇨‌ • CI • ${{ matrix.package.user }}/${{ matrix.package.repo }} + permissions: + contents: read uses: ./.github/workflows/reusable-cpp-ci.yml with: repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} From 506c8daa64b2d75e3919356ad2f7cce426fcf805 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 13:12:29 +0200 Subject: [PATCH 5/9] =?UTF-8?q?=E2=9C=A8=20add=20downstream=20Python=20CI?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 107 +++++++++++++++++- .github/workflows/reusable-python-ci.yml | 12 ++ .github/workflows/reusable-python-linter.yml | 7 ++ .../workflows/reusable-python-packaging.yml | 9 ++ .github/workflows/reusable-python-tests.yml | 7 ++ 5 files changed, 140 insertions(+), 2 deletions(-) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 031fc5f..389146d 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -20,7 +20,7 @@ concurrency: cancel-in-progress: true jobs: - cpp-downstream-test: + downstream-cpp-test: strategy: matrix: package: @@ -28,7 +28,7 @@ jobs: - { user: cda-tum, repo: mqt-qcec, setup-z3: false } - { user: cda-tum, repo: mqt-qmap, setup-z3: true } - { user: cda-tum, repo: mqt-ddsim, setup-z3: false } - name: 🇨‌ • CI • ${{ matrix.package.user }}/${{ matrix.package.repo }} + name: ${{ matrix.package.user }}/${{ matrix.package.repo }} • 🇨‌ • CI permissions: contents: read uses: ./.github/workflows/reusable-cpp-ci.yml @@ -72,3 +72,106 @@ jobs: enable-windows2025-msvc-debug: true enable-windows2025-clang-release: true enable-windows2025-clang-debug: true + + downstream-python-test: + strategy: + matrix: + package: + - { user: munich-quantum-toolkit, repo: core, setup-z3: false } + - { user: cda-tum, repo: mqt-qcec, setup-z3: false } + - { user: cda-tum, repo: mqt-qmap, setup-z3: true } + - { user: cda-tum, repo: mqt-ddsim, setup-z3: false } + - { user: cda-tum, repo: mqt-bench, setup-z3: false } + name: ${{ matrix.package.user }}/${{ matrix.package.repo }} • 🐍‌ • CI + permissions: + contents: read + uses: ./.github/workflows/reusable-python-ci.yml + with: + repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} + setup-z3: ${{ matrix.package.setup-z3 }} + upload-coverage: false + # enable running on all supported combinations + enable-ubuntu2404: true + enable-ubuntu2204: true + enable-ubuntu2404-arm: true + enable-ubuntu2204-arm: true + enable-macos13: true + enable-macos14: true + enable-macos15: true + enable-windows2022: true + enable-windows2025: true + # testing Python on Windows 11 ARM is not supported by the ecosystem at the moment + enable-windows11-arm: false + + downstream-python-linter: + strategy: + matrix: + package: + - { user: munich-quantum-toolkit, repo: core, setup-z3: false } + - { user: cda-tum, repo: mqt-qcec, setup-z3: false } + - { user: cda-tum, repo: mqt-qmap, setup-z3: true } + - { user: cda-tum, repo: mqt-ddsim, setup-z3: false } + - { user: cda-tum, repo: mqt-bench, setup-z3: false } + name: ${{ matrix.package.user }}/${{ matrix.package.repo }} • 🐍‌ • Lint + permissions: + contents: read + uses: ./.github/workflows/reusable-python-linter.yml + with: + repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} + setup-z3: ${{ matrix.package.setup-z3 }} + + downstream-python-packaging: + strategy: + matrix: + package: + - { + user: munich-quantum-toolkit, + repo: core, + setup-z3: false, + pure-python: false, + } + - { + user: cda-tum, + repo: mqt-qcec, + setup-z3: false, + pure-python: false, + } + - { + user: cda-tum, + repo: mqt-qmap, + setup-z3: true, + pure-python: false, + } + - { + user: cda-tum, + repo: mqt-ddsim, + setup-z3: false, + pure-python: false, + } + - { + user: cda-tum, + repo: mqt-bench, + setup-z3: false, + pure-python: true, + } + name: ${{ matrix.package.user }}/${{ matrix.package.repo }} • 🐍‌ • Packaging + permissions: + contents: read + uses: ./.github/workflows/reusable-python-packaging.yml + with: + repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} + setup-z3: ${{ matrix.package.setup-z3 }} + pure-python: true + # enable running on all supported combinations + enable-ubuntu2404: true + enable-ubuntu2404-arm: true + enable-macos13: true + enable-macos14: true + enable-windows2022: true + # disable commonly unused runners for packaging + enable-ubuntu2204: true + enable-ubuntu2204-arm: true + enable-macos15: false + enable-windows2025: false + # Only select MQT packages currently support packaging on Windows 11 ARM + enable-windows11-arm: false diff --git a/.github/workflows/reusable-python-ci.yml b/.github/workflows/reusable-python-ci.yml index 7cf6933..aa09514 100644 --- a/.github/workflows/reusable-python-ci.yml +++ b/.github/workflows/reusable-python-ci.yml @@ -12,6 +12,16 @@ on: workflow_call: inputs: ###---- General inputs ----------------------------------------------------------------------------------------### + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string + upload-coverage: + description: "Whether to upload the generated coverage reports" + default: true + type: boolean setup-z3: description: "Whether to set up Z3" default: false @@ -130,12 +140,14 @@ jobs: include: ${{ fromJson(needs.build-matrix.outputs.matrix) }} uses: ./.github/workflows/reusable-python-tests.yml with: + repository: ${{ inputs.repository }} runs-on: ${{ matrix.runs-on }} setup-z3: ${{ inputs.setup-z3 }} z3-version: ${{ inputs.z3-version }} python-coverage-upload: name: 📈 + if: ${{ inputs.upload-coverage }} needs: [python-tests] runs-on: ubuntu-latest permissions: diff --git a/.github/workflows/reusable-python-linter.yml b/.github/workflows/reusable-python-linter.yml index f595fd7..c1c9075 100644 --- a/.github/workflows/reusable-python-linter.yml +++ b/.github/workflows/reusable-python-linter.yml @@ -10,6 +10,12 @@ name: 🐍 • Lint on: workflow_call: inputs: + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string setup-z3: description: "Whether to set up Z3" default: false @@ -28,6 +34,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # optionally set up Z3 diff --git a/.github/workflows/reusable-python-packaging.yml b/.github/workflows/reusable-python-packaging.yml index d84e408..9729d4a 100644 --- a/.github/workflows/reusable-python-packaging.yml +++ b/.github/workflows/reusable-python-packaging.yml @@ -12,6 +12,12 @@ on: workflow_call: inputs: ###---- General inputs ----------------------------------------------------------------------------------------### + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string pure-python: description: "Whether this is a pure Python package (or contains compiled extensions)" default: false @@ -90,6 +96,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # set up uv for faster Python package management @@ -115,6 +122,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # set up uv for faster Python package management @@ -188,6 +196,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # optionally set up Z3 (non-Ubuntu only) diff --git a/.github/workflows/reusable-python-tests.yml b/.github/workflows/reusable-python-tests.yml index 21a69ff..47e0fd3 100644 --- a/.github/workflows/reusable-python-tests.yml +++ b/.github/workflows/reusable-python-tests.yml @@ -10,6 +10,12 @@ name: 🐍 • Tests on: workflow_call: inputs: + repository: + description: > + The repository to run this action on. + Defaults to the repository this workflow is running in (`github.repository`). + default: ${{ github.repository }} + type: string runs-on: description: "The platform to run the tests on" required: true @@ -34,6 +40,7 @@ jobs: # check out the repository (including submodules and all history) - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: + repository: ${{ inputs.repository }} submodules: recursive fetch-depth: 0 # optionally set up Z3 From 056a76830f4c74e35af1cd3f97d5762d23da3176 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 13:13:37 +0200 Subject: [PATCH 6/9] =?UTF-8?q?=F0=9F=9B=82=20fix=20workflow=20permissions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 389146d..256760f 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -85,6 +85,7 @@ jobs: name: ${{ matrix.package.user }}/${{ matrix.package.repo }} • 🐍‌ • CI permissions: contents: read + id-token: write uses: ./.github/workflows/reusable-python-ci.yml with: repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} From e70450aa80a5fbba5553811908e0e610cab89936 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 14:00:56 +0200 Subject: [PATCH 7/9] =?UTF-8?q?=F0=9F=94=A7=20do=20not=20upload=20coverage?= =?UTF-8?q?=20artifacts=20on=20downstream=20tests?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/reusable-python-ci.yml | 1 + .github/workflows/reusable-python-tests.yml | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/reusable-python-ci.yml b/.github/workflows/reusable-python-ci.yml index aa09514..74485ea 100644 --- a/.github/workflows/reusable-python-ci.yml +++ b/.github/workflows/reusable-python-ci.yml @@ -141,6 +141,7 @@ jobs: uses: ./.github/workflows/reusable-python-tests.yml with: repository: ${{ inputs.repository }} + upload-coverage: ${{ inputs.upload-coverage }} runs-on: ${{ matrix.runs-on }} setup-z3: ${{ inputs.setup-z3 }} z3-version: ${{ inputs.z3-version }} diff --git a/.github/workflows/reusable-python-tests.yml b/.github/workflows/reusable-python-tests.yml index 47e0fd3..8d8f4a3 100644 --- a/.github/workflows/reusable-python-tests.yml +++ b/.github/workflows/reusable-python-tests.yml @@ -16,6 +16,10 @@ on: Defaults to the repository this workflow is running in (`github.repository`). default: ${{ github.repository }} type: string + upload-coverage: + description: "Whether to upload the generated coverage reports" + default: true + type: boolean runs-on: description: "The platform to run the tests on" required: true @@ -77,6 +81,7 @@ jobs: run: uvx nox -s tests --verbose -- --cov --cov-report=xml:coverage-${{ inputs.runs-on }}.xml --cov-append # upload the report as an artifact to GitHub so that it can later be uploaded to Codecov - name: Upload 🐍 coverage report for ${{ inputs.runs-on }} + if: ${{ inputs.upload-coverage }} uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 with: name: coverage-${{ inputs.runs-on }} From 4509f8e12e6ab9cb3e97017d78d6c0df4e799e81 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 14:03:19 +0200 Subject: [PATCH 8/9] =?UTF-8?q?=F0=9F=94=A7=20do=20not=20upload=20artifact?= =?UTF-8?q?s=20on=20downstream=20packaging?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 1 + .github/workflows/reusable-python-packaging.yml | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 256760f..4c7cb5d 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -161,6 +161,7 @@ jobs: uses: ./.github/workflows/reusable-python-packaging.yml with: repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} + upload-artifacts: false setup-z3: ${{ matrix.package.setup-z3 }} pure-python: true # enable running on all supported combinations diff --git a/.github/workflows/reusable-python-packaging.yml b/.github/workflows/reusable-python-packaging.yml index 9729d4a..dffe37e 100644 --- a/.github/workflows/reusable-python-packaging.yml +++ b/.github/workflows/reusable-python-packaging.yml @@ -18,6 +18,10 @@ on: Defaults to the repository this workflow is running in (`github.repository`). default: ${{ github.repository }} type: string + upload-artifacts: + description: "Whether to upload the generated artifacts" + default: true + type: boolean pure-python: description: "Whether this is a pure Python package (or contains compiled extensions)" default: false @@ -110,6 +114,7 @@ jobs: run: uvx twine check dist/* # upload the source distribution as an artifact (adds a `dev-` prefix for PRs) - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 + if: ${{ inputs.upload-artifacts }} with: name: ${{ github.event_name == 'pull_request' && 'dev-' || '' }}cibw-sdist path: dist/*.tar.gz @@ -136,6 +141,7 @@ jobs: run: uvx twine check dist/* # upload the wheel as an artifact (adds a `dev-` prefix for PRs) - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 + if: ${{ inputs.upload-artifacts }} with: name: ${{ github.event_name == 'pull_request' && 'dev-' || '' }}cibw-wheel path: dist/*.whl @@ -226,6 +232,7 @@ jobs: # upload the wheels as an artifact (adds a `dev-` prefix for PRs) - name: Upload wheels uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 + if: ${{ inputs.upload-artifacts }} with: name: ${{ github.event_name == 'pull_request' && 'dev-' || '' }}cibw-wheels-${{ matrix.runs-on }}-${{ strategy.job-index }} path: wheelhouse/*.whl From 9284204015dd26f58b45e6dc293feaa240709212 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Wed, 23 Apr 2025 14:22:10 +0200 Subject: [PATCH 9/9] =?UTF-8?q?=F0=9F=A9=B9=20fix=20the=20`pure-python`=20?= =?UTF-8?q?flag=20for=20CD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/downstream.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 4c7cb5d..460fe46 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -163,7 +163,7 @@ jobs: repository: ${{ matrix.package.user }}/${{ matrix.package.repo }} upload-artifacts: false setup-z3: ${{ matrix.package.setup-z3 }} - pure-python: true + pure-python: ${{ matrix.package.pure-python }} # enable running on all supported combinations enable-ubuntu2404: true enable-ubuntu2404-arm: true