Skip to content

check

check #1381

Workflow file for this run

name: check
on:
workflow_dispatch:
push:
branches: ["main"]
tags-ignore: ["**"]
pull_request:
schedule:
- cron: "0 8 * * *"
concurrency:
group: check-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
test:
runs-on: ${{ matrix.os || 'ubuntu-latest' }}
name: ${{ matrix.env }}${{ matrix.suffix || ''}}
strategy:
fail-fast: false
matrix:
env:
- "3.14"
- "3.13"
- "3.12"
- "3.11"
- "3.10"
- type
- dev
- pkg_meta
os:
- ubuntu-24.04
suffix:
- "-linux-x86_64-gnu"
include:
- env: "3.14"
os: windows-2025
suffix: -windows-x86_64-msvc
- env: "3.14"
os: macos-15
suffix: -macos-aarch64-none
- env: "3.14"
os: macos-15
suffix: -macos-x86_64-none
- env: meta-3.14
- env: meta-3.13
- env: meta-3.12
- env: meta-3.11
- env: meta-3.10
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Install the latest version of uv
uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0
with:
enable-cache: false
cache-dependency-glob: "pyproject.toml"
- name: Install tox
run: uv tool install --python-preference only-managed --python 3.14 tox --with .
- name: Install Python
if: (startsWith(matrix.env, '3.') && matrix.env != '3.14') || startsWith(matrix.env, 'meta-')
run: |
VERSION="${{ matrix.env }}"
VERSION="${VERSION#meta-}"
if [[ "$VERSION" =~ -arm64(-|$) || "$VERSION" =~ -x86_64(-|$) ]]; then
# For explicit per-arch macOS meta env names, use the same value directly.
UV_VERSION="cpython-$VERSION"
else
# For non-arch-specific values, keep existing behavior.
UV_VERSION="cpython-$VERSION${{ matrix.suffix }}"
fi
uv python install --python-preference only-managed "$UV_VERSION"
- name: Setup test suite
run: tox run -vv --notest --skip-missing-interpreters false -e ${{ matrix.env }}
env:
FORCE_COLOR: "1"
UV_PYTHON_PREFERENCE: "only-managed"
- name: Run test suite
run: tox run --skip-pkg-install -e ${{ matrix.env }}
env:
FORCE_COLOR: "1"
PYTEST_ADDOPTS: "-vv --durations=20"
DIFF_AGAINST: HEAD
UV_PYTHON_PREFERENCE: "only-managed"