Skip to content

all extras added to doc env #1195

all extras added to doc env

all extras added to doc env #1195

Workflow file for this run

name: Unit tests and docs generation
on:
push:
branches:
- "**"
pull_request:
branches:
- "**"
types: [opened, synchronize, reopened, ready_for_review]
workflow_dispatch:
jobs:
check:
if: github.event.pull_request.draft == false
runs-on: ${{ matrix.os }}
strategy:
matrix:
# Full matrix only for PRs to main
os: ${{ github.event_name == 'pull_request' && github.base_ref == 'main' && fromJSON('["ubuntu-latest", "windows-latest"]') || fromJSON('["ubuntu-latest"]') }}
python-version: ${{ github.event_name == 'pull_request' && github.base_ref == 'main' && fromJSON('["3.9", "3.11", "3.12"]') || fromJSON('["3.12"]') }}
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v3
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Install dependencies
run: make install
- name: Check with ruff
run: make check-quality
- name: Test with pytest
run: make check-tests
- name: Check types
run: make check-types
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v3
with:
enable-cache: true
- name: Set up Python 3.12
run: uv python install 3.12
- name: Install only docs dependencies
run: uv sync --all-extras
- name: Build docs
run: uv run sphinx-build -b html docs/ _build/html
- name: Test docs
run: uv run sphinx-build -b doctest docs/ _build/doctest