Repository navigation
Description
Steps to reproduce
- Run
rad bicep download(invoked automatically bydeploy/install.ps1anddeploy/install.sh) in an environment where the network stalls mid-transfer while fetching the ~110MB bicep binary. - The command blocks forever with no progress and no error.
This was surfaced during PR #12836 (the install.sh sudo fix): the Validate PowerShell Installer CI job repeatedly stalled at Installing bicep... and consumed its full 10-minute budget before being cancelled, with no application error in the logs.
Observed behavior
pkg/cli/bicep/tools/download_tools.go DownloadToFolder uses http.Get (the default client, which has no Timeout) followed by io.Copy on resp.Body (no read deadline). If the connection stalls after the response headers arrive, the copy blocks indefinitely.
The retry loop in pkg/cli/bicep/bicep.go only fires on returned errors, so a hang never surfaces an error and never triggers a retry — the process just hangs until an external timeout (e.g. the CI job cancellation) kills it.
Desired behavior
DownloadToFolder should use an http.Client with a sensible request timeout and/or a context deadline, so a stalled transfer fails with an error that the existing retry loop can act on, instead of hanging forever. This applies to all platforms since the download code is shared.
Workaround
A script-level mitigation was added in the PowerShell installer (bound rad bicep download with a 300s timeout so a stall warns and continues instead of hanging) in the PR that references this issue. That is only a mitigation; the root cause is the missing timeout in the shared Go download code.
rad Version
Reproduced with the released v0.60.1 rad binary in CI (edge channel).
Operating system
Surfaced on windows-2025 GitHub-hosted runners; the underlying bug is platform-independent (shared download code).
Additional context
- Root cause:
pkg/cli/bicep/tools/download_tools.go(http.Getat theDownloadToFolderGET,io.Copyon the response body). - Retry loop that cannot recover from a hang:
pkg/cli/bicep/bicep.go. - Surfaced by: Fix install.sh escalating to sudo for user-writable $HOME/.local/bin #12836.
Activity
radius-triage commentedon Aug 27, 2026
👋 @sk593 Thanks for filing this bug report.
A project maintainer will review this report and get back to you soon. If you'd like immediate help troubleshooting, please visit our Discord server.
For more information on our triage process please visit our triage overview
radius-triage commentedon Aug 27, 2026
👍 We've reviewed this issue and have agreed to add it to our backlog. Please subscribe to this issue for notifications, we'll provide updates when we pick it up.
We also welcome community contributions! If you would like to pick this item up sooner and submit a pull request, please visit our contribution guidelines and assign this to yourself by commenting "/assign" on this issue.
For more information on our triage process please visit our triage overview
fix(build): bound bicep download with a timeout in the PowerShell ins…