ci(test): host-persistent target dir; fast fmt gate; drop dead rust-cache #176
Reference in New Issue
Block a user
Delete Branch "ci/host-persistent-target"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes the repo-side causes of the ~40-minute test runs (diagnosed from runs 597/600/601 logs).
Root cause found
The Gitea actions cache on this instance stores but never restores: run 597 tarred and uploaded a 1.85 GB cache ('Cache saved successfully'), and the very next run — same exact key, same day — logged 'No cache found'. This holds for every run checked, including master→master. Every CI run has been a full cold Bevy build (~9.5 min clippy + ~27 min test) plus ~4 wasted minutes saving a cache nobody can read.
Changes
CARGO_TARGET_DIR→ persistent path on the runner host.rust-hostis a host executor, so the filesystem carries over between runs (that's why rustup installs in 1 s). Warm builds without the cache API. A prune step resets the dir past 40 GiB. Concurrent runs are safe — cargo serialises on the target-dir lock.Swatinem/rust-cache— pure overhead until the server-side cache is fixed.fmtas its own seconds-long job gatingtestvianeeds, so a rustfmt slip fails in under a minute instead of after a full build (run 600).CARGO_BUILD_JOBS=2andline-tables-onlykept — they guard against the documented linker OOMs, and with warm builds their cost is negligible.Expectations
df -hon the runner host.Still server-side (not fixable from the repo)
The broken cache restore also slows
web-e2e(docker executor — no persistent filesystem, genuinely needs the cache server). Also, Gitea is accumulating ~2 GB of dead cache per historical run; the instance's actions-cache storage likely wants a look/purge. Happy to dig in if you point me at the runner host.🤖 Generated with Claude Code