Skip to content

Commit

Permalink
Trying to fix error on line 34
Browse files Browse the repository at this point in the history
  • Loading branch information
gregogiudici committed Sep 19, 2024
1 parent 1140462 commit 1db66be
Showing 1 changed file with 29 additions and 15 deletions.
44 changes: 29 additions & 15 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
pull_request:
push:
branches:
- main
- main
release:
types:
- published
Expand All @@ -19,6 +19,9 @@ jobs:
with:
submodules: true

- name: Install pipx
run: python -m pip install --user pipx

- name: Build SDist
run: pipx run build --sdist

Expand All @@ -30,38 +33,41 @@ jobs:
name: dist-sdist
path: dist/*.tar.gz


build_wheels:
name: Wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-12, macos-14, windows-latest]
python-version: ["3.8", "3.11"]

steps:
- uses: actions/checkout@v4
with:
submodules: true

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.x # Adjust Python version as needed
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest numpy librosa # Add numpy and other dependencies
pip install pytest numpy librosa
- uses: pypa/cibuildwheel@v2.19
- name: Build Wheels
uses: pypa/cibuildwheel@v2.19
with:
output-dir: wheelhouse

- name: Verify clean directory
run: git diff --exit-code
shell: bash

- name: Run tests
run: pytest # Ensure pytest runs here after installing the dependencies
run: pytest # Run tests after building the wheels

- name: Upload wheels
uses: actions/upload-artifact@v4
Expand All @@ -74,26 +80,34 @@ jobs:
runs-on: ubuntu-latest
needs: [build_wheels, build_sdist]
steps:
- name: Merge Artifacts
uses: actions/upload-artifact/merge@v4
- name: Download artifacts
uses: actions/download-artifact@v4
with:
name: dist-${{ matrix.os }}
path: wheelhouse

- name: Merge wheels
uses: actions/upload-artifact@v4
with:
name: dist
pattern: dist-*
path: wheelhouse

upload_all:
name: Upload if release
name: Upload to PyPI if release
needs: merge_wheels
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'

steps:
- uses: actions/setup-python@v5

- uses: actions/download-artifact@v4
- name: Download merged artifacts
uses: actions/download-artifact@v4
with:
path: dist

- uses: pypa/gh-action-pypi-publish@release/v1
- name: Upload to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.pypi_password }}
password: ${{ secrets.pypi_password }}

0 comments on commit 1db66be

Please sign in to comment.