What version of Go are you using (go version)?
1.13
Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (go env)?
GOARCH="amd64"
What did you do?
https://play.studygolang.com/p/_1kMO-E_FEq
I use an http2 client try to connect an http client.
I expect to see an protocol error or somethig that can tell me the destination is not a valiad http2 service.
What did you see instead?
I get an "unexpected EOF" error.
I think we can make the error more clearly.
According to the rfc, the last segment of [https://httpwg.org/specs/rfc7540.html#rfc.section.3.5]
Clients and servers MUST treat an invalid connection preface as a connection error (Section 5.4.1) of type PROTOCOL_ERROR.
It seems we should return PROTOCOL_ERROR
What version of Go are you using (
go version)?1.13
Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env)?GOARCH="amd64"
What did you do?
https://play.studygolang.com/p/_1kMO-E_FEq
I use an http2 client try to connect an http client.
I expect to see an protocol error or somethig that can tell me the destination is not a valiad http2 service.
What did you see instead?
I get an "unexpected EOF" error.
I think we can make the error more clearly.
According to the rfc, the last segment of [https://httpwg.org/specs/rfc7540.html#rfc.section.3.5]
It seems we should return PROTOCOL_ERROR