Closed
Description
In the asyncio's Event Loop document, some code examples will issue a DeprecationWarning
when get_event_loop()
is called:
$ python3 /tmp/hello.py
/tmp/hello.py:8: DeprecationWarning: There is no current event loop
loop = asyncio.get_event_loop()
The reason is explained in the manual of asyncio.get_event_loop:
Deprecated since version 3.10: Deprecation warning is emitted if there is no running event loop. In future Python releases, this function will be an alias of get_running_loop().
Metadata
Metadata
Assignees
Projects
Status
Done