fix/pool: report a stalled download as a stall even when the body ends cleanly #113
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/download-stall-report"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
CI run 493, the lint job on the #109 merge to main, failed in TestRelease_Fetch_StallDetector with an integrity mismatch where a stall error was expected. Root cause is a race in admitToCache, not the test. The stall timer cancels the request context, but the transport can hand the body reader a clean EOF for the truncated body before it reports the context error, so the copy returned nil, the digest check ran on the partial bytes and the error named a mismatch instead of the stall. The fix checks the stall cause after the copy and reports the stall however the read ended. A new deterministic test drives the race through a RoundTripper whose body answers the cancellation with io.EOF. Mutation check done, removing the new branch reproduces the exact CI error text. CHANGELOG Fixed bullet added. Independent of #110 and #112. Generated with Claude Code.