sourcegraph / jsonrpc2

Package jsonrpc2 provides a client and server implementation of JSON-RPC 2.0 (http://www.jsonrpc.org/specification)
MIT License
196 stars 62 forks source link

don't require a space between the Content-Length header name and value #5

Closed akhleung closed 7 years ago

akhleung commented 7 years ago

Hmm, I double-checked the spec and it looks like the space is required ... that seems unnecessarily strict compared to what HTTP headers allow.

beyang commented 7 years ago

The spec (https://github.com/Microsoft/language-server-protocol/blob/master/protocol.md#header-part) actually requires a colon and a space (": "), so instead of implementing functionality that's out of spec, let's just close this or add a more helpful error message ("could not parse content-length, expected space after colon")