Lawouach / WebSocket-for-Python

WebSocket client and server library for Python 2 and 3 as well as PyPy (ws4py 0.5.1)
https://ws4py.readthedocs.org/en/latest/
BSD 3-Clause "New" or "Revised" License
1.12k stars 288 forks source link

Give application status code 1005 when no good status code is parsed/received #181

Closed isonmad closed 7 years ago

isonmad commented 8 years ago

1005 is "designated for use in applications expecting a status code to indicate that no status code was actually present."

1002 is for telling the other endpoint that there was a protocol error. Giving the application 1002 on a parse error is misleading, as it's indistinguishable from the far endpoint complaining about something you sent being invalid.

tito commented 7 years ago

Thanks !