Closed Thioby closed 9 months ago
Just to add some more info to whoever is searching for this issue. I think this happens at least since socket.io 4.6.2 (when they started using socket.io-parser 4.2.4 with the RESERVED_EVENTS listed above).
And just to clarify: should we upgrade to socket io client-dart 3.x beta? or is it something we could avoid by downgrading socket.io to 4.6.1 (and/or force socket.io-parser 4.2.3)?
Hi, library is no longer compatible with latest socket.io. (4.7.4) In latest version of socket.io there is list reserved events : https://github.com/socketio/socket.io-parser/blob/9f76ea22b41feeade0c8819dbf3c16fd07becc2a/lib/index.ts#L11
In this library list of events looks like this:
as you can see we are missing
disconnecting
event. Now flutter apps senddisconnecting
event as EVENT type: 2, but correct type is 1.As a result, server side socket.io crash:
Error: invalid payload, type (2): \"[\"disconnecting\",\"transport close\"]\n