Skip to content

ci: skip work that passed with the same files, and shard the end-to-end tests by state - #77

Merged
helightdev merged 4 commits into
mainfrom
ci-speed
Nov 15, 2026
Merged

helightdev merged 4 commits into
mainfrom
ci-speed

Conversation

@helightdev

Copy link
Copy Markdown
Owner

CI ran every check and every playbook run on each push, about 12.5 minutes even for a docs change.

  • ci/plan.py gives each unit (Rust tests, clippy, Python tests, each e2e shard) a key from the files it reads and the week. A unit that passed leaves a marker in the cache, and a run with the same key skips it. A pull request sees its own markers and main's.
  • The e2e tests are cut into nine shards, one per shared state, each on a fresh host (SHARDS in tests/e2e/run.py). On a pull request the shards that apply the role run only for changes to the role, the plugins, the tests or the Rust code in SEAM; main runs them for any change. ansible_contract pins the variables berth hands the role, so a change elsewhere that alters them shows up and runs them.
  • The checks run on the runner in parallel jobs instead of in the dev image; the e2e runner has its own smaller image.
  • The Rust jobs restore main's target directory and set unchanged files to an old time (ci/mtimes.py), so cargo rebuilds only what changed. Only main saves those caches.
  • Boot's path filter names only the files the boots use.

A run started by hand on the branch, with no cache, took 7m43s. All nine shards also passed locally on fresh hosts with the same test counts as before.

… the runner

ci/plan.py keys each unit by the blobs it depends on and the week, and a unit that passed leaves a marker in the cache under its key. Pull requests run the shards that apply the role only for changes to the role, the tests or the Rust code that feeds it; main runs them for any change.

The Rust jobs restore main's target directory and set unchanged files to an old time (ci/mtimes.py), so cargo rebuilds only what changed.
@helightdev
helightdev merged commit e380c0a into main Nov 15, 2026
35 checks passed
@helightdev
helightdev deleted the ci-speed branch November 16, 2026 00:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant