Skip to content

chore(deps): lock file maintenance #268

chore(deps): lock file maintenance

chore(deps): lock file maintenance #268

Workflow file for this run

name: tests
on:
workflow_dispatch:
pull_request_target:
push:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
style-check:
name: "style and type checking"
if: (github.event_name != 'pull_request' && ! github.event.pull_request.head.repo.fork) || (github.event_name == 'pull_request' && (github.event.pull_request.head.repo.fork || startsWith(github.head_ref, 'dependabot/')))
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest]
python-version:
- "3.9"
- "3.10"
- "3.11"
- "3.12"
- "3.13"
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install the project
run: uv sync
- name: Style checking
run: |
uv run ruff check src tests
uv run ruff format --check src tests
- name: Type checking
run: uv run mypy src tests docs/usage/scripts
# NOTE: we intentionally isolate the API tests from style/type checking because
# the matrix above runs everything in parallel on the same machine,
# causing server overload and a bunch of failed tests.
# Pinning to a singular 3.13 instance here.
test:
name: "api testing"
if: (github.event_name != 'pull_request' && ! github.event.pull_request.head.repo.fork) || (github.event_name == 'pull_request' && (github.event.pull_request.head.repo.fork || startsWith(github.head_ref, 'dependabot/')))
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- uses: actions/setup-python@v5
with:
python-version: "3.13"
- name: Install the project
run: uv sync
- name: Run tests
run: uv run pytest