Skip to content

Release v0.4.0 — curated public snapshot #4

Release v0.4.0 — curated public snapshot

Release v0.4.0 — curated public snapshot #4

Workflow file for this run

name: CI
# Mandatory PR gate (standards/19 §4): lint + type + test must be green for both the Python
# backend and the web SPA before merge.
on:
push:
branches: ["**"]
pull_request:
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
quality:
name: Backend (ruff · mypy · pytest)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v3
with:
python-version: "3.12"
- name: Sync dependencies
run: uv sync --extra dev
- name: Lint (ruff)
run: uv run ruff check .
- name: Format check (ruff)
run: uv run ruff format --check .
- name: Type check (mypy)
run: uv run mypy src
- name: Tests (pytest + coverage gate)
# Coverage is enforced here (not in addopts) so local runs stay fast. The floor backs
# the README "coverage ≥ 85%" badge: if coverage drops below it, this job fails.
run: uv run pytest --cov=src/fathom --cov-report=term-missing --cov-fail-under=85
windows-paths:
# ADR-027 W1 seed lane: the Windows path-safety rules are pure logic that must hold on
# real Windows too. Grows into the full Windows agent suite as W1 lands; POSIX-semantic
# suites stay on the Linux job.
name: Windows path rules (pytest on windows-latest)
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v3
with:
python-version: "3.12"
- name: Sync dependencies
run: uv sync --extra dev
- name: Windows agent tests (paths · attributes · backend · enrolment bundle)
run: uv run pytest tests/test_winpaths.py tests/backends/test_winattrs.py tests/backends/test_windows_backend.py tests/deploy/test_winbundle.py -q
windows-agent-exe:
# ADR-027 W1 frozen-exe item: build fathomline-agent.exe via PyInstaller and smoke-test that it
# launches (all imports/DLLs + the packaged staging schema.sql resolve), then publish it as a
# build artifact. PyInstaller emits an OS-native exe, so this can only run on windows-latest.
name: Windows agent exe (PyInstaller build + smoke test)
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Build fathomline-agent.exe
shell: pwsh
run: ./packaging/windows/build-agent-exe.ps1 -Clean
- name: Smoke-test (launches + reaches config validation = packaging is sound)
shell: pwsh
run: |
$exe = "packaging/windows/dist/fathomline-agent.exe"
if (-not (Test-Path $exe)) { throw "fathomline-agent.exe was not produced" }
$env:FATHOM_AGENT_CONFIG = ""
$out = & $exe scan 2>&1 | Out-String
Write-Host $out
if ($out -notmatch "FATHOM_AGENT_CONFIG|config") {
throw "exe did not reach config validation — an import/DLL packaging problem"
}
Write-Host "OK: exe launches and reaches config validation"
- uses: actions/upload-artifact@v4
with:
name: fathomline-agent-exe
path: packaging/windows/dist/fathomline-agent.exe
if-no-files-found: error
web:
name: Web UI (tsc · eslint · vitest · build)
runs-on: ubuntu-latest
defaults:
run:
working-directory: src/fathom/web
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
cache: npm
cache-dependency-path: src/fathom/web/package-lock.json
- name: Install dependencies
run: npm ci
- name: Type check
run: npm run typecheck
- name: Lint
run: npm run lint
- name: Tests
run: npm test
- name: Build
run: npm run build