Enhance publish workflow with wheel verification

Added steps to verify and flatten wheels before publishing.
This commit is contained in:
BillTheMaker
2025-12-06 17:30:54 -07:00
committed by GitHub
parent 30d741b418
commit 09b4eb4510

View File

@@ -54,19 +54,26 @@ jobs:
name: Publish to PyPI name: Publish to PyPI
needs: [build_wheels] needs: [build_wheels]
runs-on: ubuntu-latest runs-on: ubuntu-latest
# Run on tags OR manual trigger
if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch'
steps: steps:
- uses: actions/download-artifact@v4 - name: Download ALL wheels
with: uses: actions/download-artifact@v4
path: dist with:
pattern: wheels-* path: dist
merge-multiple: true
- name: Verify & flatten wheels
- name: Publish to PyPI run: |
uses: PyO3/maturin-action@v1 find dist -name "*.whl" -exec mv {} dist/ \;
with: echo "Wheels found:"
pypi-token: ${{ secrets.PYPI_API_TOKEN }} ls -la dist/*.whl || echo "❌ NO WHEELS!"
command: upload echo "Directory:"
args: --skip-existing --non-interactive ls -la dist/
- name: Publish to PyPI
uses: PyO3/maturin-action@v1
with:
pypi-token: ${{ secrets.PYPI_API_TOKEN }}
command: upload
args: --skip-existing --non-interactive