net/http: context isn't canceled on client disconnection #20668
Closed
Labels
Comments
Correct. This was implemented in Go 1.8. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
What version of Go are you using (
go version
)?go version go1.7.4 linux/amd64
What operating system and processor architecture are you using (
go env
)?Arch Linux
What did you do?
Stumbled upon it on failing tests. Here's a snippet:
https://play.golang.org/p/v4ij4Elrqa
What did you expect to see?
Works like this on latest (go 1.8.*)
What did you see instead?
This test is kinda hacky b/c
.Shutdown()
and.Close()
aren't there on Go 1.7.The point is:
r.Context()
is never canceled on server's side once client disconnects.The text was updated successfully, but these errors were encountered: