name: Shared Checks on: workflow_call: permissions: contents: read env: COLUMNS: 150 jobs: pre-commit: runs-on: ubuntu-latest steps: - uses: actions/checkout@v5 - uses: astral-sh/setup-uv@v7 with: enable-cache: true version: 0.9.5 - name: Install dependencies run: uv sync --frozen --all-extras --python 3.10 - uses: pre-commit/action@v3.0.1 with: extra_args: --all-files --verbose env: SKIP: no-commit-to-branch test: name: test (${{ matrix.python-version }}, ${{ matrix.dep-resolution.name }}, ${{ matrix.os }}) runs-on: ${{ matrix.os }} timeout-minutes: 10 continue-on-error: true strategy: matrix: python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] dep-resolution: - name: lowest-direct install-flags: "--upgrade --resolution lowest-direct" - name: highest install-flags: "--upgrade --resolution highest" os: [ubuntu-latest, windows-latest] steps: - uses: actions/checkout@v5 - name: Install uv uses: astral-sh/setup-uv@v7 with: enable-cache: true version: 0.9.5 - name: Install the project run: uv sync ${{ matrix.dep-resolution.install-flags }} --all-extras --python ${{ matrix.python-version }} - name: Run pytest with coverage run: | uv run --frozen --no-sync coverage run -m pytest uv run --frozen --no-sync coverage combine uv run --frozen --no-sync coverage report doc-snippets: runs-on: ubuntu-latest steps: - uses: actions/checkout@v5 - uses: astral-sh/setup-uv@v7 with: enable-cache: true version: 0.9.5 - name: Install dependencies run: uv sync --frozen --all-extras --python 3.10 - name: Check doc snippets are up to date run: uv run --frozen scripts/update_doc_snippets.py --check # The published site is built and deployed from main, which builds this # branch's docs (via scripts/docs/build.sh) under /v1/; this branch has no # deploy workflow of its own. This job runs that same script so a change # that breaks the v1 docs fails here rather than at main's next deploy. docs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v5 - uses: astral-sh/setup-uv@v7 with: enable-cache: true version: 0.9.5 - name: Build docs run: bash scripts/docs/build.sh