cargo-mono: remove sparse index prefetch timeout#390
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9bf72cbcac
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| .timeout(PREFETCH_HTTP_TIMEOUT) | ||
| .build() | ||
| { | ||
| let http_client = match reqwest::blocking::Client::builder().build() { |
There was a problem hiding this comment.
Restore bounded timeout for sparse-index HTTP requests
Building the reqwest client without .timeout(...) removes the only per-request deadline for sparse-index prefetch, and reqwest’s default is to wait indefinitely; in run_parallel_sparse_index_lookup, the scoped worker joins wait for every lookup to return, so a single stalled TCP/HTTP read can block cargo mono publish forever before publish retries ever run. This can deadlock CI release jobs on transient network hangs instead of failing fast and retrying.
Useful? React with 👍 / 👎.
Summary
15sreqwest timeout fromcargo-monosparse index prefetch duringpublishWhy
cargo-mono publishprefetch could fail early on slower registry responses because it enforced a separate client-side timeout for sparse index lookups. Removing that override avoids premature lookup failures without changing the existing publish retry and backoff behavior.Impact
Validation
cargo fmt --all --checkcargo test