File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -2679,8 +2679,9 @@ def _send(self, **kwargs):
26792679 self ._sockfile .write (json_payload .encode () + b"\n " )
26802680 self ._sockfile .flush ()
26812681 except (OSError , ValueError ):
2682- # This means that the client has abruptly disconnected, but we'll
2683- # handle that the next time we try to read from the client instead
2682+ # We get an OSError if the network connection has dropped, and a
2683+ # ValueError if detach() if the sockfile has been closed. We'll
2684+ # handle this the next time we try to read from the client instead
26842685 # of trying to handle it from everywhere _send() may be called.
26852686 # Track this with a flag rather than assuming readline() will ever
26862687 # return an empty string because the socket may be half-closed.
You can’t perform that action at this time.
0 commit comments