fix: increase curl retry resilience in install_awf_binary.sh for transient 502s#28443
fix: increase curl retry resilience in install_awf_binary.sh for transient 502s#28443
Conversation
…e transient 502 errors The Daily Rendering Scripts Verifier (run #79) failed because the AWF binary checksum download received HTTP 502 responses from GitHub releases. The previous retry settings (--retry 3 --retry-delay 5) gave only 4 total attempts over ~20s, which was insufficient to survive a brief GitHub CDN outage. Increase to --retry 5 --retry-delay 10 --retry-max-time 180 across all three curl calls (checksums.txt, bundle, and platform binary downloads), giving up to 6 attempts over at most 3 minutes. Agent-Logs-Url: https://github.com/github/gh-aw/sessions/fe47c7ba-ffa8-45b9-b202-7ea40a860b7d Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Improves resilience of the AWF installer against transient GitHub Releases/CDN failures by increasing curl retry/backoff settings during downloads.
Changes:
- Increase
curlretries, delay, and retry time budget for downloadingchecksums.txt. - Apply the same retry settings to the Node.js bundle download.
- Apply the same retry settings to Linux/macOS binary downloads.
Show a summary per file
| File | Description |
|---|---|
| actions/setup/sh/install_awf_binary.sh | Increases curl retry resilience for checksums, bundle, and platform binaries to better handle transient 5xx errors. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 1/1 changed files
- Comments generated: 2
| # Download checksums | ||
| echo "Downloading checksums from ${CHECKSUMS_URL@Q}..." | ||
| curl -fsSL --retry 3 --retry-delay 5 -o "${TEMP_DIR}/checksums.txt" "${CHECKSUMS_URL}" | ||
| curl -fsSL --retry 5 --retry-delay 10 --retry-max-time 180 -o "${TEMP_DIR}/checksums.txt" "${CHECKSUMS_URL}" |
There was a problem hiding this comment.
The PR description mentions a “3-minute hard ceiling”, but --retry-max-time 180 only limits how long curl will keep retrying; it doesn’t cap the total wall-clock time of a successful (but slow/stalled) transfer. If a strict overall limit is desired, add --max-time (and/or other timeout/speed options), or adjust the description to match curl’s behavior.
| # Download checksums | ||
| echo "Downloading checksums from ${CHECKSUMS_URL@Q}..." | ||
| curl -fsSL --retry 3 --retry-delay 5 -o "${TEMP_DIR}/checksums.txt" "${CHECKSUMS_URL}" | ||
| curl -fsSL --retry 5 --retry-delay 10 --retry-max-time 180 -o "${TEMP_DIR}/checksums.txt" "${CHECKSUMS_URL}" |
There was a problem hiding this comment.
The curl retry flags are now repeated verbatim across multiple download sites in this script. To reduce the chance of future inconsistency, consider factoring these options into a single variable (e.g., CURL_RETRY_OPTS) and reusing it for checksums/bundle/binary downloads.
The Daily Rendering Scripts Verifier (run #79) failed at "Install AWF binary" because GitHub releases returned HTTP 502 on all download attempts. The previous
--retry 3 --retry-delay 5gave only 4 attempts over ~20 seconds — not enough to survive a brief CDN outage.Changes
actions/setup/sh/install_awf_binary.sh: Increase retry resilience on all threecurlcalls (checksums, bundle, platform binary):6 total attempts, 10s between retries, 3-minute hard ceiling. The
v0.25.28release itself is valid; this was a pure transient outage.