net/http: Transport.CancelRequest not always called if RoundTrip returns promptly when a request times out #34552
Labels
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
No.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
The tests for my project,
go.elastic.co/apm
, started failing when running against go tip.I strongly suspect 7fc2625, since it started happening today. The issue can be reproduced with https://play.golang.org/p/MQepDRMdcjL
What did you expect to see?
The program should run and exit cleanly.
What did you see instead?
The program runs for ~10 seconds and panics, due to CancelRequest not being called.
Note that this doesn't happen every time, hence the loop. If I increase the timeout to 50ms it becomes less frequent, but still fails occasionally.
The text was updated successfully, but these errors were encountered: