Skip to content

work around https://github.com/PyO3/maturin/pull/2326 #10

work around https://github.com/PyO3/maturin/pull/2326

work around https://github.com/PyO3/maturin/pull/2326 #10

Workflow file for this run

name: CI
on:
push:
branches-ignore:
- "wip*"
tags:
- "v[0-9].*"
pull_request:
schedule:
# Daily at 5:33
- cron: "33 5 * * *"
workflow_dispatch:
jobs:
list:
runs-on: ubuntu-latest
outputs:
noxenvs: ${{ steps.noxenvs-matrix.outputs.noxenvs }}
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- name: Set up nox
uses: wntrblm/[email protected]
- id: noxenvs-matrix
run: |
echo >>$GITHUB_OUTPUT noxenvs=$(
nox --list-sessions --json | jq '[.[].session]'
)
test:
needs: list
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
noxenv: ${{ fromJson(needs.list.outputs.noxenvs) }}
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- name: Install dependencies
run: sudo apt-get update && sudo apt-get install -y libenchant-2-dev
if: runner.os == 'Linux' && startsWith(matrix.noxenv, 'docs')
- name: Install dependencies
run: brew install enchant
if: runner.os == 'macOS' && startsWith(matrix.noxenv, 'docs')
- name: Set up Python
uses: quansight-labs/setup-python@v5
with:
python-version: |
3.9
3.10
3.11
3.12
3.13
3.13t
pypy3.9
pypy3.10
allow-prereleases: true
- name: Set up uv
uses: hynek/setup-cached-uv@v2
- name: Set up nox
uses: wntrblm/[email protected]
- name: Run nox
run: nox -s "${{ matrix.noxenv }}"
manylinux:
needs: test
runs-on: ubuntu-latest
strategy:
matrix:
target: [x86_64, x86, aarch64, armv7, s390x, ppc64le]
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: quansight-labs/setup-python@v5
with:
python-version: |
3.9
3.10
3.11
3.12
3.13
3.13t
pypy3.9
pypy3.10
allow-prereleases: true
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist --interpreter '3.9 3.10 3.11 3.12 3.13 python3.13t pypy3.9 pypy3.10'
sccache: "true"
manylinux: auto
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: dist-${{ github.job }}-${{ matrix.target }}
path: dist
musllinux:
needs: test
runs-on: ubuntu-latest
strategy:
matrix:
target:
- aarch64-unknown-linux-musl
- i686-unknown-linux-musl
- x86_64-unknown-linux-musl
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: quansight-labs/setup-python@v5
with:
python-version: |
3.9
3.10
3.11
3.12
3.13
3.13t
pypy3.9
pypy3.10
allow-prereleases: true
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist --interpreter '3.9 3.10 3.11 3.12 3.13 python3.13t pypy3.9 pypy3.10'
manylinux: musllinux_1_2
sccache: "true"
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: dist-${{ github.job }}-${{ matrix.target }}
path: dist
windows:
needs: test
runs-on: windows-latest
strategy:
matrix:
target: [x64, x86] # x86 is not supported by pypy
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: quansight-labs/setup-python@v5
with:
python-version: |
3.9
3.10
3.11
3.12
3.13
3.13t
${{ matrix.target == 'x64' && 'pypy3.9' || '' }}
${{ matrix.target == 'x64' && 'pypy3.10' || '' }}
allow-prereleases: true
architecture: ${{ matrix.target }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist --interpreter '3.9 3.10 3.11 3.12 3.13 python3.13t' --interpreter ${{ matrix.target == 'x64' && 'pypy3.9 pypy3.10' || '' }}
sccache: "true"
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: dist-${{ github.job }}-${{ matrix.target }}
path: dist
macos:
needs: test
runs-on: macos-latest
strategy:
matrix:
target: [x86_64, aarch64]
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: quansight-labs/setup-python@v5
with:
python-version: |
3.9
3.10
3.11
3.12
3.13
3.13t
pypy3.9
pypy3.10
allow-prereleases: true
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist --interpreter '3.9 3.10 3.11 3.12 3.13 python3.13t pypy3.9 pypy3.10'
sccache: "true"
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: dist-${{ github.job }}-${{ matrix.target }}
path: dist
sdist:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: actions/setup-python@v5
with:
python-version: 3.13
- name: Build an sdist
uses: PyO3/maturin-action@v1
with:
command: sdist
args: --out dist
- name: Upload sdist
uses: actions/upload-artifact@v4
with:
name: dist-${{ github.job }}
path: dist
release:
needs: [manylinux, musllinux, windows, macos]
runs-on: ubuntu-latest
if: "startsWith(github.ref, 'refs/tags/')"
environment:
name: PyPI
url: https://pypi.org/p/rpds-py
permissions:
contents: write
id-token: write
steps:
- uses: actions/download-artifact@v4
with:
pattern: dist-*
merge-multiple: true
- name: Publish to PyPI
uses: PyO3/maturin-action@v1
with:
command: upload
args: --non-interactive --skip-existing *
- name: Create a GitHub Release
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
uses: softprops/action-gh-release@v2
with:
files: |
*
generate_release_notes: true