Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Return no protocol instead of erroring when not agreeing on a protocol #178

Closed
flying-sheep opened this issue Nov 20, 2014 · 3 comments · Fixed by #181
Closed

Return no protocol instead of erroring when not agreeing on a protocol #178

flying-sheep opened this issue Nov 20, 2014 · 3 comments · Fixed by #181
Labels

Comments

@flying-sheep
Copy link
Contributor

sorry, my implementation of websocket subprotocols has a mistake, i.e. the spec says:

The server selects one or none of the acceptable protocols and echoes that value in its handshake to indicate that it has selected that protocol.

so instead of a Bad Request exception, we should send back no Sec-WebSocket-Protocol header at all and leave it to the client to drop the connection or carry on without protocol (however dumb that sounds).

@asvetlov
Copy link
Member

Sounds good.
Would you make a pull request?

@flying-sheep
Copy link
Contributor Author

gladly. i see that this project doesn’t use logging: wouldn’t it be useful to introduce it? then i could replace this with a warning, but it doesn’t make sense if we don’t log anything else.

/edit: i’ll just use warnings.warn.

@lock
Copy link

lock bot commented Oct 29, 2019

This thread has been automatically locked since there has not been
any recent activity after it was closed. Please open a new issue for
related bugs.

If you feel like there's important points made in this discussion,
please include those exceprts into that new issue.

@lock lock bot added the outdated label Oct 29, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 29, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants