MCPcopy Create free account
hub / github.com/python-websockets/websockets / _do_enter

Method _do_enter

src/websockets/asyncio/async_timeout.py:256–260  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

254 self._timeout_handler = self._loop.call_at(deadline, self._on_timeout)
255
256 def _do_enter(self) -> None:
257 if self._state != _State.INIT:
258 raise RuntimeError(f"invalid state {self._state.value}")
259 self._state = _State.ENTER
260 self._reschedule()
261
262 def _do_exit(self, exc_type: Optional[Type[BaseException]]) -> None:
263 if exc_type is asyncio.CancelledError and self._state == _State.TIMEOUT:

Callers 2

__enter__Method · 0.95
__aenter__Method · 0.95

Calls 1

_rescheduleMethod · 0.95

Tested by

no test coverage detected