MCPcopy Index your code
hub / github.com/python/cpython / _force_close

Method _force_close

Lib/asyncio/selector_events.py:896–907  ·  view source on GitHub ↗
(self, exc)

Source from the content-addressed store, hash-verified

894 self._force_close(exc)
895
896 def _force_close(self, exc):
897 if self._conn_lost:
898 return
899 if self._buffer:
900 self._buffer.clear()
901 self._buffer_size = 0
902 self._loop._remove_writer(self._sock_fd)
903 if not self._closing:
904 self._closing = True
905 self._loop._remove_reader(self._sock_fd)
906 self._conn_lost += 1
907 self._call_soon(self._call_connection_lost, exc)
908
909 def _call_connection_lost(self, exc):
910 try:

Callers 2

abortMethod · 0.95
_fatal_errorMethod · 0.95

Calls 4

_call_soonMethod · 0.95
clearMethod · 0.45
_remove_writerMethod · 0.45
_remove_readerMethod · 0.45

Tested by

no test coverage detected