If a server log stopped abruptly, "error" event will be emitted in client. However since no "error" listener registered, my application stopped with this error throw er; // Unhandled 'error' event
My solution is to add nop listener to error event, like this :
socket.on('error',function(){});