![]() Return True if the event loop was closed. Return True if the event loop is currently running. Note that new callbacks scheduled by callbacks will not run in thisĬase instead, they will run the next time run_forever() or The loop will run the current batch of callbacks and then exit. If stop() is called while run_forever() is running, Those that were already scheduled), and then exit. Run all callbacks scheduled in response to I/O events (and The loop will poll the I/O selector once with a timeout of zero, If stop() is called before run_forever() is called, Run the event loop until stop() is called. ![]() Return the Future’s result or raise its exception. Is implicitly scheduled to run as a asyncio.Task. Run until the future (an instance of Future) has The Examples section showcases how to work with some eventĮvent loops have low-level APIs for the following:Įxecuting code in thread or process pools SelectorEventLoop and ProactorEventLoop classes The Event Loop Implementations section documents the The Server Objects section documents types returned fromĮvent loop methods like loop.create_server() Methods such as loop.call_soon() and loop.call_later() TimerHandle instances which are returned from scheduling The Callback Handles section documents the Handle and The Event Loop Methods section is the reference documentation of This documentation page contains the following sections: Note that the behaviour of get_event_loop(), set_event_loop(),Īnd new_event_loop() functions can be altered by new_event_loop ( ) ¶Ĭreate and return a new event loop object. Set loop as the current event loop for the current OS thread. ![]() In some future Python release this will become an error. Deprecated since version 3.12: Deprecation warning is emitted if there is no current event loop.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |