Repository navigation
Retry the yarn-classic corepack probe in e2e tests - #1673
Conversation
require_yarn_classic probed `corepack yarn@<release> --version` once and, under SOCKET_PATCH_YARN_E2E_REQUIRED=1, panicked on any failure. A single DNS timeout on a Depot host therefore failed the yarn-classic 1.22.22 merge-queue leg on 2026-10-22, evicted #1653 and forced the green group behind it to rebuild (~32 queue-min, ~94 job-min). Retry the probe after 2 s and 5 s before treating the release as unavailable, and keep the last attempt's stderr in the SKIP/panic message instead of discarding it. A missing corepack binary is not retried, a wrong release still panics at once, and a release that stays unfetchable still fails the REQUIRED leg. Refs #1671 Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
bugbot run Generated by Claude Code |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 28a5f04. Configure here.
|
Burn-down agent: labeled Ready for review at
Generated by Claude Code |
Final review briefWhat it does. The yarn-classic e2e suites probe Risk: low. Only test-support code changes (1 file, +39/−23). The behavior that matters is kept: a wrong yarn version still panics on the first attempt, and a release that really can't be fetched still fails the REQUIRED leg, about 7 s later than before. Look here
Verified
Changes I made: none. Open questions: none. Auto-merge (squash) is armed, so approving sends it straight to the merge queue. Generated by Claude Code |
Fixes #1671
Problem
On 2026-10-22, merge-group run 39840895419 failed in
yarn-classic 1.22.22. Two tests ine2e_redirect_yarn_classic_buildpanicked becausecorepack yarn@1.22.22 --versionfailed once, during a DNS timeout on the Depot host (lookup cache.depot.dev ... i/o timeout90 s earlier).require_yarn_classicprobed only once, andSOCKET_PATCH_YARN_E2E_REQUIRED=1turns a failed probe into a panic. One blip:Change
crates/socket-patch-cli/tests/common/yarn_classic_vex.rs,require_yarn_classic:Stdio::null(). The SKIP/panic message now includes the last attempt's error.corepackbinary can't be spawned, because retrying can't help.I left out the script warm-up the issue also proposed. Each suite uses its own sandbox
COREPACK_HOME, and the retry alone covers the observed failure. I didn't change the yarn-berry, pnpm or rush probes, to keep this PR to one topic.Expected saving
At ~0.5 hits/day (n=1 so far), about 15 merge-queue min/day amortized on the queue's critical path and ~50 Linux job-min/day. A green run costs nothing extra: the retry only runs after a probe fails. PR feedback latency and macOS minutes don't change.
Measured result
SOCKET_PATCH_YARN_E2E_REQUIRED=1 cargo test -p socket-patch-cli --test e2e_redirect_yarn_classic_buildpassed 40/40 in 22.4 s, the same as before the change.COREPACK_NPM_REGISTRY=http://127.0.0.1:9) with an uncached release (1.22.19). Each probing test logged 3 failed attempts with corepack's stderr, then still panicked underREQUIRED=1. That adds ~7 s per probe to a leg that is already failing.ci-okandclippyare green.yarn-classic 1.22.22took 1.87 min (20:41:30 → 20:43:22), within the baseline (p50 2.15 / p90 3.34 min, n=55), so the happy path is no slower. The saving comes from avoided merge-queue evictions, which show up only after merge. The profiler will check the eviction rate.Where each test runs
All tests run where they ran before. No test moved, and no assertion was weakened. A release that really can't be fetched still fails the REQUIRED leg.
Risk
Low. The change touches only test-support code. Required checks
ci-okandclippyare unchanged.https://claude.ai/code/session_016RS4Qh9aCHhzeMGKNok1oN
Generated by Claude Code