Skip to content

Commit

Permalink
ci: Fix pure wheels if check (#525)
Browse files Browse the repository at this point in the history
Fix #523 not actually running the pure wheel building steps...
Now that that got merged to main I was able to _workflow dispatch_ it to
test, and it seems I used the wrong syntax for the ifs.

It works now:
https://github.com/CQCL/tket2/actions/runs/10214055732/job/28260696536
  • Loading branch information
aborgna-q authored Aug 5, 2024
1 parent 3047ad5 commit 67b3f13
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions .github/workflows/python-pure-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,34 +31,35 @@ jobs:
#
# Skip the workflow when triggered by a release event for any other package.
- name: Check tag
id: check-tag
run: |
echo "run=$SHOULD_RUN" >> $GITHUB_OUTPUT
env:
SHOULD_RUN: ${{ github.event_name != 'release' || ( github.ref_type == 'tag' && startsWith(github.ref, format('refs/tags/{0}-v', matrix.target.name)) ) }}

- uses: actions/checkout@v4
if: ${{ github.job.steps.check-tag.outputs.run == 'true' }}
if: ${{ steps.check-tag.outputs.run == 'true' }}
- name: Run sccache-cache
if: ${{ github.job.steps.check-tag.outputs.run == 'true' }}
if: ${{ steps.check-tag.outputs.run == 'true' }}
uses: mozilla-actions/[email protected]
- name: Install poetry
if: ${{ github.job.steps.check-tag.outputs.run == 'true' }}
if: ${{ steps.check-tag.outputs.run == 'true' }}
run: pipx install poetry
- name: Set up Python '3.10'
if: ${{ github.job.steps.check-tag.outputs.run == 'true' }}
if: ${{ steps.check-tag.outputs.run == 'true' }}
uses: actions/setup-python@v5
with:
python-version: '3.10'
cache: "poetry"

- name: Build sdist and wheels
if: ${{ github.job.steps.check-tag.outputs.run == 'true' }}
if: ${{ steps.check-tag.outputs.run == 'true' }}
run: |
cd ${{ matrix.target.name }}
poetry build -o ../dist
- name: Upload the built packages as artifacts
if: ${{ github.job.steps.check-tag.outputs.run == 'true' }}
if: ${{ steps.check-tag.outputs.run == 'true' }}
uses: actions/upload-artifact@v4
with:
name: build-${{ matrix.target.name }}-sdist
Expand Down

0 comments on commit 67b3f13

Please sign in to comment.