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

Function _get_running_loop

Lib/asyncio/events.py:765–774  ·  view source on GitHub ↗

Return the running event loop or None. This is a low-level function intended to be used by event loops. This function is thread-specific.

()

Source from the content-addressed store, hash-verified

763
764
765def _get_running_loop():
766 """Return the running event loop or None.
767
768 This is a low-level function intended to be used by event loops.
769 This function is thread-specific.
770 """
771 # NOTE: this function is implemented in C (see _asynciomodule.c)
772 running_loop, pid = _running_loop.loop_pid
773 if running_loop is not None and pid == os.getpid():
774 return running_loop
775
776
777def _set_running_loop(loop):

Callers 2

get_running_loopFunction · 0.85
get_event_loopFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…