Files
nvbench/.github/workflows/build-wheels.yml
2025-12-03 10:15:32 -05:00

59 lines
1.5 KiB
YAML

name: Build Python Wheels
on:
workflow_dispatch:
defaults:
run:
shell: bash --noprofile --norc -euo pipefail {0}
jobs:
build-wheels:
name: Build wheel (CUDA ${{ matrix.cuda }}, Python ${{ matrix.python }})
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
strategy:
fail-fast: false
matrix:
cuda: ['12', '13']
python: ['3.10', '3.11', '3.12', '3.13']
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: false
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build wheel
run: |
bash ci/build_pynvbench_wheel.sh -py-version ${{ matrix.python }} -cuda-version ${{ matrix.cuda }}
- name: Upload wheel artifact
uses: actions/upload-artifact@v4
with:
name: wheel-pynvbench-cu${{ matrix.cuda }}-py${{ matrix.python }}
path: wheelhouse/*.whl
retention-days: 7
if-no-files-found: error
verify-wheels:
name: Verify all wheels built successfully
if: ${{ always() }}
needs: build-wheels
runs-on: ubuntu-latest
steps:
- name: Check build results
run: |
if [[ "${{ needs.build-wheels.result }}" != "success" ]]; then
echo "Wheel builds failed!"
exit 1
fi
echo "All wheels built successfully!"