Skip to content

Commit

Permalink
Update package.yml Actions workflow to use one runner per architecture
Browse files Browse the repository at this point in the history
  • Loading branch information
althonos committed Oct 25, 2024
1 parent 6c11c67 commit 076a1f9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 89 deletions.
99 changes: 10 additions & 89 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,6 @@ jobs:
wheel-linux-aarch64:
name: Build Linux wheels (Aarch64)
runs-on: ubuntu-22.04
strategy:
matrix:
python-tag:
- cp37-manylinux_aarch64
- cp38-manylinux_aarch64
- cp39-manylinux_aarch64
- cp310-manylinux_aarch64
- cp311-manylinux_aarch64
- cp312-manylinux_aarch64
- cp313-manylinux_aarch64
- pp37-manylinux_aarch64
- pp38-manylinux_aarch64
- pp39-manylinux_aarch64
- pp310-manylinux_aarch64
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -37,35 +23,18 @@ jobs:
uses: pypa/[email protected]
env:
CIBW_ARCHS: aarch64
CIBW_BUILD: ${{ matrix.python-tag }}
CIBW_BUILD_VERBOSITY: 2
CIBW_BEFORE_BUILD: pip install cython
CIBW_TEST_COMMAND: python -m unittest pyfastani.tests -vv
CIBW_BUILD: '*-manylinux_aarch64'
CIBW_TEST_REQUIRES: importlib-resources biopython
with:
output-dir: dist
- uses: actions/upload-artifact@v4
with:
name: wheels-${{ matrix.python-tag }}
name: wheels-manylinux_aarch64
path: dist/*

wheel-linux-x86_64:
name: Build Linux wheels (x86-64)
runs-on: ubuntu-20.04
strategy:
matrix:
python-tag:
- cp37-manylinux_x86_64
- cp38-manylinux_x86_64
- cp39-manylinux_x86_64
- cp310-manylinux_x86_64
- cp311-manylinux_x86_64
- cp312-manylinux_x86_64
- cp313-manylinux_x86_64
- pp37-manylinux_x86_64
- pp38-manylinux_x86_64
- pp39-manylinux_x86_64
- pp310-manylinux_x86_64
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -74,35 +43,18 @@ jobs:
uses: pypa/[email protected]
env:
CIBW_ARCHS: x86_64
CIBW_BUILD: ${{ matrix.python-tag }}
CIBW_BEFORE_BUILD: pip install cython
CIBW_BUILD_VERBOSITY: 2
CIBW_TEST_COMMAND: python -m unittest pyfastani.tests -vv
CIBW_BUILD: '*-manylinux_x86_64'
CIBW_TEST_REQUIRES: importlib-resources biopython
with:
output-dir: dist
- uses: actions/upload-artifact@v4
with:
name: wheels-${{ matrix.python-tag }}
name: wheels-manylinux_x86_64
path: dist/*

wheel-macos-x86_64:
name: Build MacOS wheels (x86-64)
runs-on: macOS-12
strategy:
matrix:
python-tag:
- cp37-macosx_x86_64
- cp38-macosx_x86_64
- cp39-macosx_x86_64
- cp310-macosx_x86_64
- cp311-macosx_x86_64
- cp312-macosx_x86_64
- cp313-macosx_x86_64
- pp37-macosx_x86_64
- pp38-macosx_x86_64
- pp39-macosx_x86_64
- pp310-macosx_x86_64
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -111,31 +63,19 @@ jobs:
uses: pypa/[email protected]
env:
CIBW_ARCHS: x86_64
CIBW_BUILD: ${{ matrix.python-tag }}
CIBW_BEFORE_BUILD: pip install cython
CIBW_BUILD_VERBOSITY: 2
CIBW_TEST_COMMAND: python -m unittest pyfastani.tests -vv
CIBW_BUILD: '*-macosx_x86_64'
CIBW_TEST_REQUIRES: importlib-resources
CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET=10.12
with:
output-dir: dist
- uses: actions/upload-artifact@v4
with:
name: wheels-${{ matrix.python-tag }}
name: wheels-macosx_x86_64
path: dist/*

wheel-macos-aarch64:
name: Build MacOS wheels (Aarch64)
runs-on: macOS-12
strategy:
matrix:
python-tag:
- cp38-macosx_arm64
- cp39-macosx_arm64
- cp310-macosx_arm64
- cp311-macosx_arm64
- cp312-macosx_arm64
- cp313-macosx_arm64
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -144,35 +84,19 @@ jobs:
uses: pypa/[email protected]
env:
CIBW_ARCHS: arm64
CIBW_BUILD: ${{ matrix.python-tag }}
CIBW_BEFORE_BUILD: pip install cython
CIBW_BUILD_VERBOSITY: 2
CIBW_TEST_COMMAND: python -m unittest pyfastani.tests -vv
CIBW_BUILD: '*-macosx_arm64'
CIBW_TEST_REQUIRES: importlib-resources
CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET=10.12
with:
output-dir: dist
- uses: actions/upload-artifact@v4
with:
name: wheels-${{ matrix.python-tag }}
name: wheels-macosx_arm64
path: dist/*

# wheel-win32-x86_64:
# name: Build Windows wheels (x86-64)
# runs-on: windows-2019
# strategy:
# matrix:
# python-tag:
# - cp37-win_amd64
# - cp38-win_amd64
# - cp39-win_amd64
# - cp310-win_amd64
# - cp311-win_amd64
# - cp312-win_amd64
# - cp313-win_amd64
# - pp37-win_amd64
# - pp38-win_amd64
# - pp39-win_amd64
# steps:
# - uses: actions/checkout@v4
# with:
Expand All @@ -185,17 +109,14 @@ jobs:
# uses: pypa/[email protected]
# env:
# CIBW_ARCHS: AMD64
# CIBW_BUILD: ${{ matrix.python-tag }}
# CIBW_BEFORE_BUILD: pip install cython
# CIBW_BUILD_VERBOSITY: 2
# CIBW_TEST_COMMAND: python -m unittest pyfastani.tests -vv
# CIBW_BUILD: '*-win_amd64'
# CIBW_TEST_REQUIRES: importlib-resources
# with:
# output-dir: dist
# - name: Store built wheels
# uses: actions/upload-artifact@v4
# with:
# name: wheels-${{ matrix.python-tag }}
# name: wheels-win_amd64
# path: dist/*

sdist:
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ free-threaded-support = false
before-build = "pip install scikit-build-core cython"
build-frontend = { name = "pip", args = ["--no-build-isolation"] }
build-verbosity = 1
test-command = "python -m unittest pyfastani.tests -v"

[tool.coverage.run]
plugins = ["Cython.Coverage"]
Expand Down

0 comments on commit 076a1f9

Please sign in to comment.