MCPcopy
hub / github.com/tornadoweb/tornado / _is_connreset

Method _is_connreset

tornado/iostream.py:1044–1052  ·  view source on GitHub ↗

Return ``True`` if exc is ECONNRESET or equivalent. May be overridden in subclasses.

(self, exc: BaseException)

Source from the content-addressed store, hash-verified

1042 self.io_loop.update_handler(self.fileno(), self._state)
1043
1044 def _is_connreset(self, exc: BaseException) -> bool:
1045 """Return ``True`` if exc is ECONNRESET or equivalent.
1046
1047 May be overridden in subclasses.
1048 """
1049 return (
1050 isinstance(exc, (socket.error, IOError))
1051 and errno_from_exception(exc) in _ERRNO_CONNRESET
1052 )
1053
1054
1055class IOStream(BaseIOStream):

Callers 2

_read_to_bufferMethod · 0.95
_handle_writeMethod · 0.95

Calls 1

errno_from_exceptionFunction · 0.90

Tested by

no test coverage detected