Add self-hosted Modal CI and runner DX polish (#1) #6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| workflow_dispatch: | |
| concurrency: | |
| group: ci-${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| test: | |
| name: python | |
| runs-on: | |
| - self-hosted | |
| - modal | |
| - acme | |
| - job-${{ github.run_id }}-${{ github.job }} | |
| timeout-minutes: 30 | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0 | |
| with: | |
| enable-cache: true | |
| cache-dependency-glob: "uv.lock" | |
| - name: Set up Python | |
| run: uv python install | |
| - name: Install the project | |
| run: uv sync --locked --all-extras --dev | |
| - name: Ruff check | |
| run: uv run ruff check src/runner_modal tests examples | |
| - name: Ruff format | |
| run: uv run ruff format --check src/runner_modal tests examples | |
| - name: ty | |
| run: uv run ty check | |
| - name: Pytest | |
| run: uv run pytest tests |