From 75dc5900e7b228f069841aa658a7d32adf17dbc3 Mon Sep 17 00:00:00 2001 From: Alberto Gimeno Date: Tue, 15 Sep 2026 08:45:23 +0200 Subject: [PATCH] Harden Rust CLI download retries Increase transient download retries from three to five so short GitHub release outages have a 31-second bounded backoff window in both build modes. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- rust/build/in_process.rs | 4 ++-- rust/build/out_of_process.rs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/rust/build/in_process.rs b/rust/build/in_process.rs index c1aa583f9c..4d6ec38613 100644 --- a/rust/build/in_process.rs +++ b/rust/build/in_process.rs @@ -861,8 +861,8 @@ fn cached_download( data } -/// Maximum number of HTTP attempts (one initial + this many retries on transient errors). -const MAX_RETRIES: u32 = 3; +/// Maximum retries after the initial HTTP attempt for transient errors. +const MAX_RETRIES: u32 = 5; /// Download `url` with bounded retries on transient network errors. Backoff is /// exponential starting at 1s. 4xx responses fail fast; 5xx and connect/read diff --git a/rust/build/out_of_process.rs b/rust/build/out_of_process.rs index c0a9dd3050..4d7ba889ea 100644 --- a/rust/build/out_of_process.rs +++ b/rust/build/out_of_process.rs @@ -553,8 +553,8 @@ fn cached_download( data } -/// Maximum number of HTTP attempts (one initial + this many retries on transient errors). -const MAX_RETRIES: u32 = 3; +/// Maximum retries after the initial HTTP attempt for transient errors. +const MAX_RETRIES: u32 = 5; /// Download `url` with bounded retries on transient network errors. Backoff is /// exponential starting at 1s. 4xx responses fail fast; 5xx and connect/read