Skip to content

fix: missing wheel for Python 3.12 #38

fix: missing wheel for Python 3.12

fix: missing wheel for Python 3.12 #38

Workflow file for this run

name: "Python"
on:
push:
branches:
- master
release:
types:
- published
jobs:
test:
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
# choose compiler with C++20 support
- { os: ubuntu-20.04, CC: gcc-10, CXX: g++-10 }
- { os: macos-11, CC: gcc-10, CXX: g++-10 }
- { os: windows-2022, CC: "", CXX: "" }
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Build and install
env:
CC: ${{ matrix.config.CC }}
CXX: ${{ matrix.config.CXX }}
run: pip install --verbose .[tests]
- name: Run tests with pytest
run: pytest
build-sdist:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Build sdist
run: pipx run build --sdist
- uses: actions/upload-artifact@v4
with:
name: dist-sdist
path: dist/*.tar.gz
build-wheels:
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
# choose compiler with C++20 support
- { os: ubuntu-20.04, CC: gcc-10, CXX: g++-10 } # using manylinux container anyway
- { os: macos-11, CC: gcc-10, CXX: g++-10 }
- { os: windows-2022, CC: "", CXX: "" }
steps:
- uses: actions/checkout@v4
- name: Build wheels
env:
CC: ${{ matrix.config.CC }}
CXX: ${{ matrix.config.CXX }}
# disable builds of PyPy and musllinux wheels (toolchain broken for C++20)
CIBW_SKIP: 'pp* *-musllinux_*'
uses: pypa/[email protected]
- uses: actions/upload-artifact@v4
with:
name: dist-wheels-${{ matrix.config.os }}
path: wheelhouse/*.whl
publish:
needs: [test, build-sdist, build-wheels]
runs-on: ubuntu-20.04
steps:
- uses: actions/download-artifact@v4
with:
# unpacks builds artifacts into dist/
pattern: dist-*
path: dist
merge-multiple: true
- name: Publish package to Test PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository-url: https://test.pypi.org/legacy/
skip-existing: true
- name: Publish package to PyPI
if: github.event_name == 'release' && github.event.action == 'published'
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}