[Hard Python] [Chapter 2 - asynchronous IO] 2. Execution of asynchronous tasks in event loop
Continue First words After the event loop is created, how to run the concurrent task and asynchronous IO task? By asyncio The code of run shows that loop run_ until_ Complete is the method of running a collaborative process. It is defined as follows:
# base_events.py
class BaseEventLoop(events.AbstractEventLoop):
def run_until_complete(s ...
Added by ashrust on Sun, 20 Feb 2022 15:45:08 +0200
Building wheels from scratch: gather of Python 3 asyncio
preface
The book continues from the above: This paper builds the third wheel, which is also a very common function gather in the asyncio package
1, Knowledge preparation
● compared with the first two functions, gather is used more frequently because it supports the "simultaneous" execution of multiple collaborative tasks
● understa ...
Added by fotakis on Tue, 18 Jan 2022 20:29:15 +0200