SocketCluster / socketcluster-client

JavaScript client for SocketCluster
MIT License
292 stars 91 forks source link

EXCEPTION: SocketProtocolError: Socket hung up #50

Closed ansarizafar closed 6 years ago

ansarizafar commented 8 years ago

I am getting this error in firefox and in chrome for android. Please help.

DarkMukke commented 6 years ago

in your worker.js add

    scServer.on('closure', (socket) => {
    });
    scServer.on('disconnection', (socket) => {
    });

to suppress the message

jondubois commented 6 years ago

This is a generic error which means that the client could not reach the server; there could be many reasons for this; bad internet connection, proxies, incorrect parameters passed when creating the client socket, etc...