Nightly Install Check #170
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: Nightly Install Check | |
| on: | |
| schedule: | |
| - cron: "30 3 * * *" # 03:30 UTC daily (30 min after UAT) | |
| workflow_dispatch: {} | |
| permissions: | |
| contents: read | |
| jobs: | |
| fresh-install: | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, macos-latest] | |
| python-version: ["3.12", "3.13", "3.14"] | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 10 | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install from source | |
| run: uv sync --locked --all-packages --group dev | |
| - name: Run studyloop doctor | |
| run: | | |
| output=$(uv run studyloop doctor --json) || true | |
| echo "$output" | python3 -c " | |
| import json, sys | |
| checks = json.load(sys.stdin) | |
| failed = [c for c in checks if c['status'] == 'fail'] | |
| warned = [c for c in checks if c['status'] == 'warn'] | |
| passed = [c for c in checks if c['status'] == 'pass'] | |
| skipped = [c for c in checks if c['status'] == 'skip'] | |
| print(f'Doctor: {len(passed)} passed, {len(warned)} warned, {len(skipped)} skipped, {len(failed)} failed') | |
| for f in failed: | |
| print(f' FAIL: {f[\"category\"]}/{f[\"name\"]} — {f[\"message\"]}') | |
| # Fail CI on core/database/config failures; warnings are acceptable | |
| # (e.g. missing optional tmux, agents, or voice deps on CI) | |
| core_fails = [f for f in failed if f['category'] in ('core', 'database', 'config')] | |
| if core_fails: | |
| print(f'::error::{len(core_fails)} core check(s) failed') | |
| sys.exit(1) | |
| " | |
| - name: Verify CLI entry point | |
| run: uv run studyloop --version | |
| - name: Verify agent-session-tools entry point | |
| run: uv run session-export --help | |
| # A4: the real `uv tool install` path -- the one a fresh clone's | |
| # ./scripts/install.sh actually uses -- otherwise has zero execution | |
| # coverage anywhere in CI. This runs it for real, into a scratch tool | |
| # dir, and proves the two global console scripts it installs work. | |
| installer: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 30 | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1 | |
| with: | |
| python-version: "3.12" | |
| - name: Run scripts/install.sh | |
| # HOME is isolated because `studyloop install agents` writes into it | |
| # (~/.kiro, ~/.claude, ~/.codex, ~/.config/opencode). With a fresh HOME | |
| # there is no Python 3.12 either, so this also exercises the script's | |
| # `uv python install` fallback every night. | |
| env: | |
| HOME: ${{ runner.temp }}/home | |
| UV_TOOL_DIR: ${{ runner.temp }}/tools | |
| UV_TOOL_BIN_DIR: ${{ runner.temp }}/bin | |
| run: mkdir -p "$HOME" && ./scripts/install.sh --non-interactive --no-smoke | |
| - name: Verify installed CLI entry points | |
| env: | |
| UV_TOOL_BIN_DIR: ${{ runner.temp }}/bin | |
| run: | | |
| "$UV_TOOL_BIN_DIR/studyloop" --version | |
| "$UV_TOOL_BIN_DIR/session-export" --help |