Skip to content

Update tests

Update tests #16

Workflow file for this run

# This file is autogenerated by maturin v1.10.2

Check failure on line 1 in .github/workflows/publish.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/publish.yml

Invalid workflow file

(Line: 24, Col: 25): Unrecognized named-value: 'env'. Located at position 10 within expression: fromJSON(env.PYTHON_VERSIONS), (Line: 24, Col: 25): Unexpected value '${{ fromJSON(env.PYTHON_VERSIONS) }}', (Line: 47, Col: 25): Unrecognized named-value: 'env'. Located at position 10 within expression: fromJSON(env.PYTHON_VERSIONS), (Line: 47, Col: 25): Unexpected value '${{ fromJSON(env.PYTHON_VERSIONS) }}', (Line: 70, Col: 25): Unrecognized named-value: 'env'. Located at position 10 within expression: fromJSON(env.PYTHON_VERSIONS), (Line: 70, Col: 25): Unexpected value '${{ fromJSON(env.PYTHON_VERSIONS) }}', (Line: 94, Col: 25): Unrecognized named-value: 'env'. Located at position 10 within expression: fromJSON(env.PYTHON_VERSIONS), (Line: 94, Col: 25): Unexpected value '${{ fromJSON(env.PYTHON_VERSIONS) }}'
# To update, run
#
# maturin generate-ci github
#
name: Publish to PyPI
on:
release:
types: [published]
permissions:
contents: read
env:
PYTHON_VERSIONS: '["3.11","3.12","3.13","3.14"]'
jobs:
linux:
if: github.repository_owner == 'ccxlv' && startsWith(github.event.release.tag_name, 'v')
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ${{ fromJSON(env.PYTHON_VERSIONS) }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: x86_64-unknown-linux-gnu
args: --release --out dist --find-interpreter
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-linux-x86_64
path: dist
windows:
if: github.repository_owner == 'ccxlv' && startsWith(github.event.release.tag_name, 'v')
runs-on: windows-latest
strategy:
matrix:
python-version: ${{ fromJSON(env.PYTHON_VERSIONS) }}
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: x86_64-pc-windows-msvc
args: --release --out dist --find-interpreter
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
- name: Upload wheels
uses: actions/upload-artifact@v5
with:
name: wheels-windows-x64
path: dist
macos-x86_64:
if: github.repository_owner == 'ccxlv' && startsWith(github.event.release.tag_name, 'v')
runs-on: macos-15-intel
strategy:
matrix:
python-version: ${{ fromJSON(env.PYTHON_VERSIONS) }}
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: x86_64-apple-darwin
args: --release --out dist --find-interpreter
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
- name: Upload wheels
uses: actions/upload-artifact@v5
with:
name: wheels-macos-x86_64-apple-darwin
path: dist
macos-aarch64:
if: github.repository_owner == 'ccxlv' && startsWith(github.event.release.tag_name, 'v')
runs-on: macos-latest
strategy:
matrix:
arch: [aarch64]
python-version: ${{ fromJSON(env.PYTHON_VERSIONS) }}
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.arch }}-apple-darwin
args: --release --out dist --find-interpreter
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
- name: Upload wheels
uses: actions/upload-artifact@v5
with:
name: wheels-macos-${{ matrix.arch }}-apple-darwin
path: dist
sdist:
if: github.repository_owner == 'ccxlv' && startsWith(github.event.release.tag_name, 'v')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build sdist
uses: PyO3/maturin-action@v1
with:
command: sdist
args: --out dist
- name: Upload sdist
uses: actions/upload-artifact@v4
with:
name: wheels-sdist
path: dist
release:
if: (github.repository_owner == 'ccxlv') && ${{ startsWith(github.event.release.tag_name, 'v') }}
name: Release
runs-on: ubuntu-latest
needs: [linux, windows, macos-x86_64, macos-aarch64, sdist]
permissions:
# Use to sign the release artifacts
id-token: write
# Used to upload release artifacts
contents: write
# Used to generate artifact attestation
attestations: write
steps:
- name: Install uv
uses: astral-sh/setup-uv@v7
- name: Download artifacts
uses: actions/download-artifact@v4
with:
path: dist
- name: Generate artifact attestation
uses: actions/attest-build-provenance@v2
with:
subject-path: "dist/**/*"
- name: Publish to PyPI
run: uv publish "dist/**/*"