Skip to content

Commit

Permalink
Use native GH Actions ARM runners (#13)
Browse files Browse the repository at this point in the history
* Run arm wheel builds on native arm runners!

* A little bit of cleanup to remove old jobs
  • Loading branch information
bryanwweber authored Jan 20, 2025
1 parent 686ef83 commit a561cfa
Showing 1 changed file with 10 additions and 17 deletions.
27 changes: 10 additions & 17 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ env:
jobs:
dump:
name: Dump the input parameters for the workflow
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Dump Event Payload
run: jq . "$GITHUB_EVENT_PATH"
Expand All @@ -35,7 +35,7 @@ jobs:
post-pending-status:
name: Post a pending workflow status to Cantera/cantera
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
env:
GITHUB_TOKEN: ${{ secrets.CANTERA_REPO_STATUS }}
outputs:
Expand Down Expand Up @@ -146,20 +146,17 @@ jobs:
echo ----- End of Metadata -----
build-wheels:
name: Build ${{ matrix.os }} ${{ matrix.arch }} for py${{ matrix.python || '-all' }}
name: Build ${{ matrix.os }} ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
needs: ["sdist", "post-pending-status"]
outputs:
job-status: ${{ job.status }}
strategy:
matrix:
# Wheel builds are fast except for aarch64, so split that into multiple jobs,
# one for each Python version
os: [ubuntu-latest]
arch: [aarch64]
python: ["3.10", "3.11", "3.12", "3.13"]
include:
- os: ubuntu-latest
- os: ubuntu-24.04-arm
arch: aarch64
- os: ubuntu-24.04
arch: x86_64
- os: windows-2022
arch: AMD64
Expand Down Expand Up @@ -201,11 +198,6 @@ jobs:
incoming-sha: ${{ needs.post-pending-status.outputs.incoming-sha }}

# Linux steps
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
with:
platforms: all
if: matrix.arch != 'x86_64' && runner.os == 'Linux'
- name: Set up CIBW environment
run: |
PYTHON="${{ matrix.python }}"
Expand All @@ -214,6 +206,7 @@ jobs:
echo "CIBW_BUILD=${CIBW_BUILD}" | tee -a $GITHUB_ENV
if: runner.os == 'Linux'

# Non-Linux steps
- name: Install boost
# Our custom manylinux images already have Boost installed
if: runner.os != 'Linux'
Expand Down Expand Up @@ -262,7 +255,7 @@ jobs:

- name: Save the cache
uses: actions/cache/save@v4
if: always() && steps.restore-built-libraries.outputs.cache-hit != 'true'
if: always() && runner.os != 'Linux' && steps.restore-built-libraries.outputs.cache-hit != 'true'
with:
path: ${{ github.workspace }}/cache
key: ${{ steps.restore-built-libraries.outputs.cache-primary-key }}
Expand Down Expand Up @@ -290,7 +283,7 @@ jobs:

publish-files-to-pypi:
name: Publish distribution files to PyPI
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
outputs:
job-status: ${{ job.status }}
needs:
Expand All @@ -312,7 +305,7 @@ jobs:

send_status_to_cantera:
name: Send jobs status to Cantera/cantera
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
needs:
- "post-pending-status"
- "sdist"
Expand Down

0 comments on commit a561cfa

Please sign in to comment.