Repository navigation
ci(workflows): run each CI lane only on the code it covers - #5514
Conversation
Strix Halo lanes ran on almost every PR because their filters were `src/**` and `tests/**`, while several lanes missed files that decide their result: the first-run `gaia init` hardware test ignored the model-pull client (#1655's path), six hardware lanes ignored the Lemonade start script they run, the unit suite ignored the util scripts, workflow files and docs its tests read, and most lanes ignored the shared setup-venv action and the root conftest. Each pull_request filter now lists what its lane runs, imports, installs or reads. Docs-only and website-only PRs run only their own lanes, the Lemonade smoke test (no GAIA Python at all) runs only when the pin or start scripts move, and the Linux CLI, dependency-review, PyPI and docs workflows gain the filters they lacked. Replaying the last 14 days of runs, this skips about 35k Strix Halo, 3k Strix Point and 3k hosted runner-minutes. util/check_ci_path_coverage.py (lint --ci-paths, and --all) keeps it that way: it derives each lane's dependencies from its own steps and fails on a file the filter misses or a source file no scoped lane covers. `--changed` lists the workflows a set of paths would trigger.
|
Probe PRs ran only the lanes each change can affect. A docs-only or website-only change no longer starts the Linux CLI integration test, the PyPI build or dependency review.
🔍 Technical details
|
|
Verdict: Approve with suggestions This PR makes each CI lane run only on the files that can change its result. The expensive Strix Halo lanes stop firing on docs, frontend and unrelated test changes, and several lanes that silently skipped files they depend on now trigger on them. The most important fix is the first-run Real-world evidenceN/A: CI-config, lint-tooling and test-only change, and no evidence bundle was produced. I ran the new check on this checkout and it passes ( 🔍 Technical detailsIssues found 🟢 🟢 The guard doesn't cover run steps that use a Checked and fine
Strengths
|
A PR changing only the root uv.lock skipped dependency review once the lane was scoped to manifests. Also state in the guard's docstring that pytest steps run from a working-directory, and scripts called by scripts, are not analysed.
|
Both suggestions are applied in bf8d620: dependency review now triggers on |
tests/unit/eval/test_eval_lane_matrix.py started reading it in #5513, and the new path-coverage check flagged that the lane running it would not trigger.
Resolves conflicts with #5509 and #5514. The agent-ui hub manifest is no longer published (#5509), so it no longer follows core and is dropped from the stamped fields. The workflow path filters take main's util/** blocks; lint.yml adds docs/docs.json and test_unit.yml adds hub/agents/gaia/npm/** so the path-coverage guard covers every file the version check reads.
…5521) Nothing in CI installed GAIA the way a user does and then checked that it works. The existing smokes build their own packages, use a stub agent, and stop at "the files landed". So a release could ship an installer that doesn't install or doesn't run, and nobody would know until a user tried it. This workflow takes a release's own installers and runs each one on a clean GitHub-hosted runner: silent install, headless launch, health check, quit, uninstall, and a check that nothing is left behind. It covers the Windows one-setup in all three choices, the desktop app's own setup, an upgrade from v0.25.0, the macOS .dmg and .pkg on both chips, Ubuntu 22.04/24.04 .deb and AppImage, Fedora .rpm, a .deb upgrade, and the new install.sh/install.ps1 (pinned to the release by `GAIA_RELEASE_TAG` since amd#5509). Every phase is timed against thresholds measured from five real runs. **On v0.25.1-rc2, 15 of 21 rows pass end to end. The other 6 hit real installer bugs, now filed:** - amd#5526: the GAIA agent won't start on Ubuntu 22.04, Debian 12 or RHEL 9 (Linux build needs glibc 2.38). The shipped v0.25.0 agent is affected too. - amd#5527: the desktop app's .deb and the terminal's .deb are both named `gaia`, so installing one removes the other. The documented `apt remove gaia-desktop` also fails. - amd#5528: `gaia-desktop` isn't on PATH after the .deb, though the docs say to run it. - amd#5529: install.sh fails on Intel Macs. `cryptography` 49+ has no Intel macOS wheel and needs Rust to build. - amd#5531: on Windows, `gaia uninstall --purge` can't delete the venv it runs from. - amd#5530 and amd#5532 (lower impact): the Windows setup ships a different gaia-tui build than the raw binaries; terminal-only installs suggest `gaia init`, which they don't have. Those five are listed in `installer/headless/known_failures.json`, so the run is green but shows "known #N". An entry fails the run again once its bug stops reproducing, so it has to be removed with the fix. This PR also adds one path to test_unit.yml's filter, which fixes main's red lint: amd#5509 added a test that reads `binaries.lock.json`, and amd#5514's coverage guard wants the lane to trigger on it. <details> <summary>🔍 Technical details</summary> **v0.25.1-rc2 results** (run 39659946919, the last of the five measurement runs). A release candidate publishes no terminal .pkg/.deb/.rpm, so those rows are rebuilt in the run from rc2's own gaia-tui and gaia-agent with the repo's build scripts. A final release must carry them. | Row | OS | Source | Download | Install | Upgrade | Launch | Health | Preflight | Quit | Uninstall | Leftovers | Findings | |---|---|---|---|---|---|---|---|---|---|---|---|---| | `fedora-tui-rpm` | Fedora (container) | rebuilt from the release's binaries | n/a | pass 16s | n/a | pass 0s | pass 4s | pass 0s | n/a | pass 0s | pass 0s | none | | `mac-arm64-agent-ui-dmg` | macOS arm64 | release | pass 2s | pass 17s | n/a | pass 10s | pass 18s | n/a | pass 2s | pass 0s | pass 0s | none | | `mac-arm64-install-sh` | macOS arm64 | release | n/a | pass 7s | n/a | pass 2s | pass 4s | pass 0s | n/a | pass 1s | pass 0s | none | | `mac-arm64-tui-pkg` | macOS arm64 | rebuilt from the release's binaries | n/a | pass 3s | n/a | pass 0s | pass 4s | pass 0s | n/a | pass 0s | pass 0s | none | | `mac-x64-install-sh` | macOS x64 | release | n/a | known amd#5529 12s | n/a | skipped (amd#5529) | skipped (amd#5529) | skipped (amd#5529) | n/a | skipped (amd#5529) | skipped (amd#5529) | none | | `mac-x64-tui-pkg` | macOS x64 | rebuilt from the release's binaries | n/a | pass 4s | n/a | pass 0s | pass 9s | pass 0s | n/a | pass 0s | pass 0s | none | | `ubuntu22-agent-ui-deb` | Ubuntu 22.04 | release | pass 1s | pass 15s | n/a | pass 10s | pass 4s | n/a | pass 2s | pass 3s | pass 0s | known amd#5527, known amd#5528 | | `ubuntu22-appimage` | Ubuntu 22.04 | release | pass 1s | pass 0s | n/a | pass 10s | pass 17s | n/a | pass 1s | pass 0s | pass 0s | none | | `ubuntu22-install-sh` | Ubuntu 22.04 | release | n/a | pass 11s | n/a | pass 5s | known amd#5526 4s | pass 0s | n/a | pass 2s | pass 0s | none | | `ubuntu22-tui-deb` | Ubuntu 22.04 | rebuilt from the release's binaries | n/a | pass 8s | n/a | pass 0s | known amd#5526 2s | pass 0s | n/a | pass 2s | pass 0s | none | | `ubuntu24-agent-ui-deb` | Ubuntu 24.04 | release | pass 1s | pass 6s | n/a | pass 10s | pass 5s | n/a | pass 1s | pass 2s | pass 0s | known amd#5527, known amd#5528 | | `ubuntu24-appimage` | Ubuntu 24.04 | release | pass 2s | pass 0s | n/a | pass 10s | pass 7s | n/a | pass 1s | pass 0s | pass 0s | none | | `ubuntu24-install-sh` | Ubuntu 24.04 | release | n/a | pass 13s | n/a | pass 4s | pass 7s | pass 0s | n/a | pass 2s | pass 0s | none | | `ubuntu24-tui-deb` | Ubuntu 24.04 | rebuilt from the release's binaries | n/a | pass 8s | n/a | pass 0s | pass 6s | pass 0s | n/a | pass 2s | pass 0s | none | | `ubuntu24-tui-deb-upgrade` | Ubuntu 24.04 | rebuilt from the release's binaries | n/a | pass 7s | pass 5s | pass 0s | pass 6s | n/a | n/a | pass 2s | pass 0s | none | | `win-agent-ui-exe` | Windows x64 | release | pass 2s | pass 20s | n/a | pass 11s | pass 42s | n/a | pass 6s | pass 2s | pass 2s | none | | `win-install-ps1` | Windows x64 | release | n/a | pass 39s | n/a | pass 8s | pass 14s | pass 1s | n/a | known amd#5531 2s | skipped (amd#5531) | none | | `win-setup-both` | Windows x64 | release | pass 2s | pass 62s | n/a | pass 11s | pass 43s | pass 46s | pass 6s | pass 3s | pass 1s | none | | `win-setup-tui` | Windows x64 | release | pass 2s | pass 34s | n/a | pass 0s | pass 28s | pass 46s | n/a | pass 1s | pass 1s | none | | `win-setup-ui` | Windows x64 | release | pass 3s | pass 40s | n/a | pass 11s | pass 48s | n/a | pass 4s | pass 3s | pass 2s | none | | `win-setup-upgrade` | Windows x64 | release | pass 3s | pass 122s | pass 37s | pass 11s | pass 10s | n/a | pass 6s | pass 2s | pass 1s | none | **Thresholds** (median / p95 / threshold in seconds; 5 samples each, runs 39656352046, 39657296287, 39658130298, 39659110158, 39659946919; runner images ubuntu22, ubuntu24, ubuntu26 (the Fedora container's host), macos26 (macos-latest, arm64), macos15 (macos-15-intel) and win25-vs2026; some images rolled to a new version during the runs, and both versions are recorded). Formula: `ceil(max(p95 × 1.5, p95 + 60))`. The +60 s floor keeps a 3 s phase from failing on one slow runner. Download is reported but not gated: p95 ran up to 2.7× the median, and it measures the CDN, not the installer. Refresh with `python installer/headless/propose_thresholds.py --runs 5 --write`. | Row | Install | First launch to healthy | Upgrade | Uninstall | |---|---|---|---|---| | `fedora-tui-rpm` | 16 / 16 / **77** | 5 / 6 / **66** | - | 0 / 0 / **61** | | `mac-arm64-agent-ui-dmg` | 17 / 19 / **80** | 21 / 28 / **88** | - | 0 / 0 / **61** | | `mac-arm64-install-sh` | 10 / 12 / **72** | 11 / 12 / **73** | - | 2 / 2 / **63** | | `mac-arm64-tui-pkg` | 3 / 3 / **64** | 4 / 7 / **67** | - | 0 / 0 / **61** | | `mac-x64-tui-pkg` | 6 / 15 / **75** | 17 / 18 / **79** | - | 0 / 0 / **61** | | `ubuntu22-agent-ui-deb` | 13 / 14 / **75** | 18 / 20 / **81** | - | 3 / 3 / **64** | | `ubuntu22-appimage` | 0 / 0 / **61** | 14 / 25 / **85** | - | 0 / 0 / **61** | | `ubuntu22-install-sh` | 8 / 13 / **74** | - | - | 2 / 2 / **62** | | `ubuntu22-tui-deb` | 11 / 31 / **92** | - | - | 3 / 3 / **63** | | `ubuntu24-agent-ui-deb` | 6 / 8 / **68** | 15 / 17 / **77** | - | 2 / 3 / **63** | | `ubuntu24-appimage` | 0 / 0 / **61** | 18 / 18 / **78** | - | 0 / 0 / **61** | | `ubuntu24-install-sh` | 10 / 12 / **73** | 11 / 11 / **72** | - | 2 / 2 / **62** | | `ubuntu24-tui-deb` | 8 / 14 / **75** | 6 / 6 / **67** | - | 2 / 2 / **63** | | `ubuntu24-tui-deb-upgrade` | 7 / 12 / **72** | 6 / 6 / **67** | 5 / 6 / **66** | 2 / 2 / **63** | | `win-agent-ui-exe` | 20 / 36 / **96** | 54 / 58 / **119** | - | 3 / 3 / **64** | | `win-install-ps1` | 35 / 39 / **99** | 22 / 24 / **84** | - | - | | `win-setup-both` | 61 / 64 / **125** | 59 / 87 / **148** | - | 3 / 5 / **65** | | `win-setup-tui` | 34 / 37 / **97** | 19 / 28 / **89** | - | 1 / 1 / **61** | | `win-setup-ui` | 40 / 44 / **104** | 45 / 58 / **119** | - | 3 / 3 / **64** | | `win-setup-upgrade` | 92 / 117 / **177** | 19 / 20 / **81** | 33 / 37 / **97** | 2 / 3 / **63** | - "Healthy": the desktop app's backend answers `/api/health` at the release's version, with `gaia init` skipped because it downloads models. The terminal completes one `gaia-tui chat --agent gaia --query` turn through the installed gaia-agent against `fake_model_server.py`. With no Lemonade it must refuse within 120 s and name the fix (Linux/macOS refuse in under 1 s; Windows, where the setup always installs Lemonade, takes about 46 s to report it isn't running). - The journey scripts refuse to run outside GitHub Actions and keep everything under `$RUNNER_TEMP`. Install-script rows run with a sandbox `HOME`/`USERPROFILE`. - Triggers: release tags (waits up to 5 h for assets, then fails naming what's missing), `workflow_dispatch` with `release_tag`, and PRs on installer, install-script and download-page paths. With no tag it uses the newest release whose assets are all attached. PRs don't build installers. - Intel macOS uses `macos-15-intel` (macos-13 was retired in Dec 2025). The Debian bookworm smoke stays in tui_installers.yml. - The measurement runs went to a scratch branch with a temporary push trigger and an rc2 pin. Neither is in this PR. </details> ## Test plan - [x] Five consecutive full runs against v0.25.1-rc2 green on the scratch branch (39656352046, 39657296287, 39658130298, 39659110158, 39659946919) - [x] `pytest tests/unit/installer/test_installer_headless.py`: 39 passed (naming, timing records, known-failure matching and staleness, thresholds, fake server, workflow/script agreement, scripts refuse outside CI) - [x] `python util/lint.py --all`: everything passes except Tool Descriptions, which fails locally only (site-packages `gaia`, as noted in amd#5514) - [x] `python util/check_ci_path_coverage.py`: passes over all tracked files - [ ] This PR's own "Installer journeys (headless)" run is green
The scarce Strix Halo pool was running hardware tests on almost every PR, because those lanes triggered on all of
src/**andtests/**, including docs, the Agent UI frontend, and tests they never run. At the same time, several lanes missed files that decide their result. The worst case: the first-rungaia inithardware test didn't trigger on the model-pull client, which is the path #1655 broke. Each lane now triggers on what it actually runs, imports, installs or reads, and a new lint check keeps it that way. Replaying the last 14 days of PR and main-push runs through the new filters skips about 35k Strix Halo minutes (28% of PR-lane Halo time, roughly 290 hours a week), 2.8k Strix Point and 3.0k hosted, net of the runs the fixes add.Test plan
python util/lint.py --all: every check passes, including the newCI Path Coverage.Tool Descriptionsfails locally only because that shell'sgaiaresolves to a site-packages install; CI uses the editable one.pytest $(grep -rl .github/workflows tests/unit hub/agents/*/python/tests)(968 passed).pytest tests/unit/test_check_ci_path_coverage.py tests/unit/test_flagship_ci.py(83 passed). The last class pins the policy: docs-only runs only the docs lanes, website-only onlywebsite-ci, TUI runsbuild_tui, and a frontend.tsxruns no hardware lane.🔍 Technical details
Under-triggering found (a PR changing only this file skipped the lane):
test_gaia_init_hw(Halo, 150 min/run):src/gaia/llm/lemonade_client.pyandlemonade_choice.py, the model-pull pathgaia init --force-modelstakes.installer/scripts/start-lemonade.ps1, which they run.test_npu_embedderalso missed theinstall-lemonadeaction, so a Lemonade pin bump never ran it..github/actions/setup-venvis used by about 12 lanes, and almost none listed it.conftest.py,tests/conftest.pyandpyproject.toml(pytest config) were missing from most pytest lanes.setup.pywas missing fromtest_sd.test_unit: about 20util/scripts its tests import (release_tag.py,eval_lane_matrix.py, …), 9 workflow files read by contract tests (publish.yml,release_components.yml, …), 13 doc pages checked for drift,hub/agents/*/python,installer/{debian,nsis,README.md},scripts/dev, andwebsite/src/scripts/download-target.ts.test_email_agent/test_email_agent_unit/test_chat_agent: about 10src/gaiapackages their tests import directly (connectors, hub, skills, ui, eval, …) plus fixtures (tests/fixtures/email/**).test_gaia_agent:build_flagship_sidecar.ymlanddocs/guides/starter-skills.mdx, both read by its tests.build_tui: the flagship pins andutil/scripts its called installer workflows run.docs.ymlmissedutil/release_tag.py(imported byvalidate_release_notes.py).test_electronmissed the rootpackage.json/lock itsnpm ciinstalls.Over-triggering removed:
test_lemonade_serversrc/gaia/llm/**,installer/**, tests*lemonade*.ps1, install action, manifests. It runs no GAIA Python.test_examples(integration)src/gaia/**examples/**, the packages examples import, the LLM client stacktest_agent_sdk,test_gaia_cli_windowssrc/**,tests/**test_embeddingssrc/gaia/rag/**(never imported)test_gaia_cli_linuxsrc/gaia/**minus frontend trees, plus its teststest_gaia_agenttests/**dependency-reviewpypi,docsmain;pypiscoped to what the wheel packages +README.mdThe "LLM client stack" shared by the hardware lanes is
src/gaia/llm/**, the 12 daemon moduleslemonade_clientimports,installer/init_command.py(the minimum Lemonade version),utils/**, and the leaf modules (config,env,logger,ports,version).Merge queue:
mainhas no required status checks, and since March the queue merges in about 20s without dispatchingmerge_groupruns. A skipped path-filtered check can't leave a PR pending. If a check becomes required, it needs either no filter (likeskill_audit.yml) or a job-level filter with an always-running summary job.Guard (
util/check_ci_path_coverage.py,lint.py --ci-paths). It builds on #4124's run-step parser. For each PR-triggered workflow, it derives what the workflow runs, imports, installs and reads, following called workflows and local actions, and fails when the filter misses one. It also fails on a source file no path-scoped lane covers, and on allowlist entries that excuse nothing.--changedlists the workflows a change triggers:git diff --name-only origin/main... | python util/check_ci_path_coverage.py --changed -. Known limits are stated in its docstring: transitivesrcimports aren't required (the unit and import-every-module lanes cover import-time breakage), and lanes that drive the CLI end to end are scoped by hand.Estimate method: 28,342 Actions runs from Oct 7–20, with each PR run mapped to its PR's changed files (fork runs mapped by head branch, main pushes by the squash commit's
(#N)). Each run was replayed through the old and new filters, then costed at that workflow's mean job minutes per pool from about 4,000 sampled jobs. Release and eval workflows were left untouched.