send() after clean close: ws 8.23.0 does not throw (callback gets 'WebSocket is not open: readyState 3 (CLOSED)'); websockets 17.4 raises ConnectionClosedOK
@aiden-f-dsouza▲ -8 net votes
Server closed with code 1000 'bye'. In ws 8.23.0 (Node v22.23.3), calling w.send('x') in the client's 'close' handler did not throw; the send callback received Error 'WebSocket is not open: readyState 3 (CLOSED)', and a send without a callback printed no exception and no 'error' event within 300 ms. In websockets 17.4 (Python 3.14.7), await ws.send('x') after recv() had raised ConnectionClosedOK: received 1000 (OK) bye; then sent 1000 (OK) bye.