[upstream handoff] fix: apply a request timeout to every forge HTTP client - #9
Draft
rigelbuild-bot wants to merge 1 commit into
Draft
rigelbuild-bot wants to merge 1 commit into
rigelbuild-bot wants to merge 1 commit into
Conversation
…lient This branch is based on upstream v0.5.4 (0c03418), not on this fork's main. Matt pulls it and pushes it to the upstream Codeberg repo (codeberg.org/abrenneke/jj-vine). The two sections below are the text to open the upstream PR with; they are the deliverable, not this fork PR's own description. ## Upstream PR title fix: apply a request timeout to every forge HTTP client ## Upstream PR description `reqwest` applies no request timeout by default. A forge that accepts the TCP connection but never sends a response leaves the client blocked in the socket read indefinitely, with no output and no way out but an external kill. The GitHub, GitLab, Forgejo, and Azure DevOps clients are each built from a bare `reqwest::Client::builder()`, so none of them has a timeout. This routes all four constructors through a shared `http_client_builder()` that applies a 30-second timeout, so a client cannot be built without one. The forge constructors still add their own TLS and CA options on top before calling `.build()`. Adds a test that points a client at a listener which accepts and never responds: with the timeout the request errors within a few seconds; a control using the old bare builder is still pending when a short outer deadline fires. Co-authored-by: Matt Wilkinson <matt@rigel.build>
rigel-mintaka
force-pushed
the
upstream-vcs/upstream-forge-timeout
branch
from
September 11, 2026 23:25
0e4e115 to
051761d
Compare
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.
This branch is based on upstream v0.5.4 (0c03418), not on this fork's main. Matt pulls it and pushes it to the upstream Codeberg repo (codeberg.org/abrenneke/jj-vine). The two sections below are the text to open the upstream PR with; they are the deliverable, not this fork PR's own description.
Upstream PR title
fix: apply a request timeout to every forge HTTP client
Upstream PR description
reqwestapplies no request timeout by default. A forge that accepts the TCP connection but never sends a response leaves the client blocked in the socket read indefinitely, with no output and no way out but an external kill. The GitHub, GitLab, Forgejo, and Azure DevOps clients are each built from a barereqwest::Client::builder(), so none of them has a timeout.This routes all four constructors through a shared
http_client_builder()that applies a 30-second timeout, so a client cannot be built without one. The forge constructors still add their own TLS and CA options on top before calling.build().Adds a test that points a client at a listener which accepts and never responds: with the timeout the request errors within a few seconds; a control using the old bare builder is still pending when a short outer deadline fires.
Co-authored-by: Matt Wilkinson matt@rigel.build