Skip to content

Build(Rust): Restore unchanged Wasm artifacts from the Turbo cache - #505

Merged
1aron merged 5 commits into
mainfrom
ci/faster-validation
Nov 7, 2026
Merged

1aron merged 5 commits into
mainfrom
ci/faster-validation

Conversation

@1aron

@1aron 1aron commented Nov 7, 2026 •

Copy link
Copy Markdown
Member

Why

The quality-linux job takes about 22.6 minutes (example run). This is caused by how CI is set up, not by outdated dependencies (Astro 7.4, Vite 8.3, Playwright 1.64 and Turbo 2.11 are all current). One avoidable cost: every job compiled the Rust Wasm bindings from scratch (~3.5 min on Linux, ~5 min on macOS). Turbo then replayed its cached outputs over them anyway.

Changes

  • Build(Rust): build:rust:wasm now runs the cached Turbo build:artifacts tasks instead of calling cargo xtask build-wasm all directly. It compiles only when crates, Cargo or the toolchain change. Locally: cold 61s, cached 48ms, and the artifacts are byte-identical to the direct xtask build. This applies to quality-linux, e2e-linux, compat-*, the release build and deploy-site.
  • Build(Rust): the tasks run one at a time. Runners don't have the pinned toolchain, and three tasks starting together made rustup auto-install it concurrently and fail (could not rename 'downloaded' file). The failure is reproduced locally with an empty RUSTUP_HOME. Cargo's build lock already serializes the compiles, so running them one at a time costs nothing.
  • CI(Validation): removes the second audit:i18n, because site build already runs it.

Tried and reverted

Checking two release-site profiles at a time per browser cut verification from 198s to 133s on local efficiency cores. On the 4-vCPU runner the three browsers already use the whole CPU: it only went from 414s to 394s, and one networkidle navigation timed out. Reverted.

Note

This PR's own runs missed the Turbo cache for Wasm, so they still compile it. Pull requests restore the cache but never save it, so the saving shows up on main after a push has saved a cache entry for these task hashes.

🤖 Generated with Claude Code

1aron and others added 5 commits November 8, 2026 02:18
build:rust:wasm called cargo xtask build-wasm directly, bypassing the
cached build:artifacts tasks. Every CI job therefore spent about 3.5
minutes recompiling the Wasm bindings, after which Turbo replayed its
cached outputs over them anyway. Running the same tasks through Turbo
compiles only when crates, Cargo or the toolchain change and restores
byte-identical artifacts otherwise.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each engine walked its 68 profiles one by one, mostly waiting for network
idle, fonts and axe. A small pool per engine (--concurrency, default 2)
overlaps that waiting; on efficiency cores the run dropped from 198s to
133s. Entries are sorted by their place in the profile matrix, so the
report is identical to the sequential one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The site build already runs audit:i18n before rendering pages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
On a runner without the pinned toolchain, the three cargo xtask tasks
started together and each made rustup auto-install it, racing on the
same download files ("could not rename 'downloaded' file"). Cargo's
build lock already serializes the compiles, so one task at a time costs
nothing and lets the first install the toolchain for the rest.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…owser"

This reverts commit ea018df. On the 4-vCPU CI runner the three browsers
already saturate the CPU: two pages per engine shortened verification only
from 414s to 394s, and the extra load made a networkidle navigation time
out. The local measurement on efficiency cores did not represent CI.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@1aron 1aron changed the title CI(Validation): Cut repeated Wasm builds and serial browser verification Build(Rust): Restore unchanged Wasm artifacts from the Turbo cache Nov 7, 2026
@1aron
1aron merged commit 78ae261 into main Nov 7, 2026
19 of 21 checks passed
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