fix(docs-examples): retry yarn add and surface errors on final attempt#23538
Merged
Conversation
setup_project in docs/examples/ts/aztecjs_runner/run.sh ran each `yarn add` with `> /dev/null 2>&1`. Under `set -euo pipefail` a transient yarn-add failure silently aborted the runner with rc=1 and no diagnostic output, which dequeued PR #23344 from the merge queue when aztecjs_advanced's link install flaked. Wrap yarn add in a small retry helper that keeps the existing silent behaviour on success but unsilences stderr on the final attempt so the next flake leaves a usable trace in CI logs.
PhilWindle
approved these changes
May 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
PR #23344 (
merge-train/spartan) was dequeued from the merge queue on the x8-full grind withdocs/examples/bootstrap.sh executeexitingrc=1and no diagnostic in the log (ci.aztec-labs.com/480b0d23d93a3e87):setup_project()indocs/examples/ts/aztecjs_runner/run.shruns eachyarn addwith> /dev/null 2>&1. Underset -euo pipefail, a transientyarn addfailure (link or registry flake) silently exits the runner with no output.aztecjs_advancedis the largest link install in the suite (6@aztec/*packages), so it's the one that catches a bad day.Change
Add a small
yarn_add_with_retryhelper:yarn addup to 3 times, sleeping 5s between attempts.All three
yarn addcall sites insetup_projectare routed through it (link deps, npm deps, andtypescript/tsx).Test plan
docs/examples/ts/aztecjs_runner/run.sh advancedsucceeds end-to-end.docs/examples/bootstrap.sh executepasses on a clean grind; on a flake, the failure showsyarn addoutput instead of an emptyrc=1.Created by claudebox · group:
slackbot