Skip to content

skip changelog(deps): bump actions/checkout from 6 to 7 #223

skip changelog(deps): bump actions/checkout from 6 to 7

skip changelog(deps): bump actions/checkout from 6 to 7 #223

Workflow file for this run

name: Build
on:
# Trigger the workflow on push or pull request,
# but only for the main branch
push:
branches:
- main
- master
tags:
- '*'
pull_request:
branches:
- main
- master
jobs:
build_wheels:
name: Wheels ${{ matrix.os }} ${{ matrix.archs }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
archs: [auto32, auto64]
include:
- os: macos-latest
archs: x86_64
- os: macos-latest
archs: arm64
fail-fast: false
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
- name: Setup MSVC (win32)
if: ${{ matrix.os == 'windows-latest' && matrix.archs == 'auto32' }}
uses: bus1/cabuild/action/msdevshell@e22aba57d6e74891d059d66501b6b5aed8123c4d # v1
with:
architecture: 'x86'
- name: Remove unwanted linker (win32)
if: ${{ matrix.os == 'windows-latest' && matrix.archs == 'auto32' }}
run: rm "c:\Program Files\Git\usr\bin\link.exe"
- name: Build wheels
uses: pypa/cibuildwheel@v4.0.0
env:
CIBW_ARCHS: ${{ matrix.archs }}
- uses: actions/upload-artifact@v7
with:
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }}
path: ./wheelhouse/*.whl
make_sdist:
name: Make SDist
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
- name: Build SDist
run: pipx run build --sdist
- uses: actions/upload-artifact@v7
with:
name: cibw-sdist
path: dist/*.tar.gz
upload_all:
needs: [build_wheels, make_sdist]
permissions:
id-token: write
runs-on: ubuntu-latest
if: github.ref_type == 'tag'
steps:
- uses: actions/download-artifact@v8
with:
pattern: cibw-*
path: dist
merge-multiple: true
- uses: pypa/gh-action-pypi-publish@release/v1
doc_lint_cov:
name: Documentation, Linting and Coverage
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
- uses: actions/setup-python@v6
with:
# Update according to NEP-29
python-version: '3.11'
cache: 'pip'
- name: Install package
run: |
pip install -v .[all]
- name: Build documentation
run: |
sphinx-build -W -b html docs/ _build/html
- name: Upload documentation
uses: actions/upload-artifact@v7
with:
name: Documentation
path: _build/html
- name: Code style and tests
run: |
pytest --pyargs uarray
- name: mypy
run: |
mypy src/uarray
- name: Run clang-format style check for C/C++ code.
uses: jidicula/clang-format-action@v4.18.0
with:
clang-format-version: '19'
check-path: 'src'
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v7
with:
directory: 'coverage/coverage*.xml'
env_vars: OS,PYTHON
fail_ci_if_error: false
verbose: true
scipy_fft:
name: Run SciPy FFT tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
- uses: actions/setup-python@v6
with:
# Update according to NEP-29
python-version: '3.11'
cache: 'pip'
- name: Install package
run: |
pip install -v .[tests] pytest"<7"
pip install scipy==1.9.3
- name: SciPy tests
run: |
import scipy.fft
assert scipy.fft.test()
shell: python