signalr_client icon indicating copy to clipboard operation
signalr_client copied to clipboard

SocketException: Reading from a closed socket

Open wilson0506 opened this issue 4 years ago • 1 comments

Hi, I have encountered this problem. I am wondering how to fix it.

Unhandled Exception: SocketException: Reading from a closed socket #0 _RawSecureSocket.read (dart:io/secure_socket.dart:699:7) #1 _Socket._onData (dart:io-patch/socket_patch.dart:1830:27) #2 _rootRunUnary (dart:async/zone.dart:1134:38) #3 _CustomZone.runUnary (dart:async/zone.dart:1031:19) #4 _CustomZone.runUnaryGuarded (dart:async/zone.dart:933:7) #5 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:338:11) #6 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:265:7) #7 _SyncStreamControllerDispatch._sendData (dart:async/stream_controller.dart:766:19) #8 _StreamController._add (dart:async/stream_controller.dart:642:7) #9 _StreamController.add (dart:async/stream_controller.dart:588:5) #10 _RawSecureSocket._sendReadEvent (dart:io/secure_socket.dart:1018:19) #11 _rootRun (dart:async/zone.dart:1122:38) #12 _CustomZone.run (dart:async/zone.dart:1023:19) #13 _CustomZone.runGuar<…>

wilson0506 avatar Apr 01 '20 09:04 wilson0506

I get this frequently too and I'm unsure of the cause. I have a timer running to periodically reconnect which works well enough for what I'm doing, but it's still a hack. Did you ever find a cause for this?

hallidev avatar May 21 '20 14:05 hallidev