MCPcopy Index your code
hub / github.com/RustPython/RustPython / call_soon

Method call_soon

Lib/asyncio/base_events.py:817–834  ·  view source on GitHub ↗

Arrange for a callback to be called as soon as possible. This operates as a FIFO queue: callbacks are called in the order in which they are registered. Each callback will be called exactly once. Any positional arguments after the callback will be passed to

(self, callback, *args, context=None)

Source from the content-addressed store, hash-verified

815 return timer
816
817 def call_soon(self, callback, *args, context=None):
818 """Arrange for a callback to be called as soon as possible.
819
820 This operates as a FIFO queue: callbacks are called in the
821 order in which they are registered. Each callback will be
822 called exactly once.
823
824 Any positional arguments after the callback will be passed to
825 the callback when it is called.
826 """
827 self._check_closed()
828 if self._debug:
829 self._check_thread()
830 self._check_callback(callback, 'call_soon')
831 handle = self._call_soon(callback, args, context)
832 if handle._source_traceback:
833 del handle._source_traceback[-1]
834 return handle
835
836 def _check_callback(self, callback, method):
837 if (coroutines.iscoroutine(callback) or

Callers 1

start_tlsMethod · 0.95

Calls 4

_check_closedMethod · 0.95
_check_threadMethod · 0.95
_check_callbackMethod · 0.95
_call_soonMethod · 0.95

Tested by

no test coverage detected