Skip to content

ci(e2e): install bun from npm instead of apt unzip plus setup-bun - #3407

Merged
tyler-dane merged 1 commit into
mainfrom
ci/e2e-bun-install-without-apt
Sep 5, 2026
Merged

ci(e2e): install bun from npm instead of apt unzip plus setup-bun#3407
tyler-dane merged 1 commit into
mainfrom
ci/e2e-bun-install-without-apt

Conversation

@tyler-dane

Copy link
Copy Markdown
Contributor

Fixes: no issue. Follow-up to the manual rerun PR #3388 needed on e2e run 33938967483.

What and why

The e2e shards ran apt-get update && apt-get install unzip inside the Playwright container so oven-sh/setup-bun could unzip Bun on a cache miss. That fetch pulled ~30 MB of Ubuntu package indexes from archive.ubuntu.com on every shard. In the newest 100 e2e runs it had a p50 of 6s, a p95 of 47s, and an unbounded tail: all 10 red e2e gates in that window were shards cancelled by the 12-minute job timeout while still inside that step, which is why the failure read as "cancelled" instead of a failed step.

This replaces the apt step and setup-bun with npm install --global bun@1.3.14, capped at 2 minutes. The npm bun package resolves a platform package that carries the binary, so the shard now touches only the registry bun install already depends on and no Ubuntu mirror. bun lint now checks the e2e bun@ pin against the bun-version pin in test-unit.yml, the same way it checks the Dockerfiles.

Also adds docs/CI-CD/ci-audit-2026-09.md with the before numbers for the whole audit (per-job p50/p95, failure split, shard balance, tests that passed only on retry). Follow-up PRs land the other fixes and append to its change log.

Verify

Selected packages: scripts
Checks run: type-check, lint, knip
Failed: test:scripts:fast
VERDICT: FAIL

The three failing tests are agent-loop-next picker and two agent-loop launch quota recovery cases, all with .github/scripts/agent-loop-next.sh: line 21: mapfile: command not found. That is macOS /bin/bash 3.2 lacking a bash 4 builtin; those scripts and tests are not touched by this diff and pass on the Linux runner. The other 116 scripts tests, type-check, lint (including the new pin check), and knip pass locally. CI on Linux is the arbiter for this PR, and this PR's own e2e run exercises the new install step directly.

🤖 Generated with Claude Code

The e2e shards ran apt-get update inside the Playwright container to get
unzip for oven-sh/setup-bun. That fetch pulled ~30 MB of Ubuntu package
indexes on every shard, crawled to the 12-minute job timeout often enough
to be the top cause of red e2e gates in the 2026-09 audit, and surfaced as
"cancelled" shards rather than a failed step. The npm bun package resolves a
platform package that carries the binary, so the shard now touches only the
registry bun install already depends on, capped at 2 minutes.

bun lint now checks the e2e workflow's bun@ pin against test-unit.yml the
same way it checks the Dockerfiles.

Adds docs/CI-CD/ci-audit-2026-09.md with the before numbers.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@tyler-dane
tyler-dane marked this pull request as ready for review September 5, 2026 14:44
@tyler-dane tyler-dane added the agent-automerge Agent-loop finished; merge-guard may squash-merge label Sep 5, 2026
@tyler-dane
tyler-dane enabled auto-merge September 5, 2026 14:44
@tyler-dane
tyler-dane added this pull request to the merge queue Sep 5, 2026
Merged via the queue into main with commit da80b3b Sep 5, 2026
32 checks passed
@tyler-dane
tyler-dane deleted the ci/e2e-bun-install-without-apt branch September 5, 2026 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent-automerge Agent-loop finished; merge-guard may squash-merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant