0

My SignalR works as expected and I can catch a lot of errors client side using the following:-

    this._connection.error(function (error:any) {
        console.log(error);
    });

The problem I have is when I stop the server to test the disconnect functionality I get something similar to the following:-

enter image description here

I've had this problem in the past using SignalR on different platforms, and I've finally reached my annoyance threshold.

This particular error will stop once the 30 second reconnect stops, however my question is how can I stop/handle all SignalR console errors?

Lee.Winter
  • 700
  • 9
  • 16
  • I believe this error is written to the log by the browser and not by the signalr and as such is not catcheable/suppressable. See: http://stackoverflow.com/questions/31978298/suppress-websocket-connection-to-xyz-failed – Pawel Nov 14 '16 at 19:44
  • For any who stumble accross this later, as mentioned [here](http://stackoverflow.com/questions/31002592/javascript-doesnt-catch-error-in-websocket-instantiation) its actually part of the spec. If I could handle these events then it could also have a security implication. – Lee.Winter Nov 28 '16 at 08:18

0 Answers0