File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,6 +30,30 @@ Pending removal in Python 3.16
3030 use :func: `inspect.iscoroutinefunction ` instead.
3131 (Contributed by Jiahao Li and Kumar Aditya in :gh: `122875 `.)
3232
33+ * :mod: `asyncio ` policy system is deprecated and will be removed in Python 3.16.
34+ In particular, the following classes and functions are deprecated:
35+
36+ * :class: `!asyncio.AbstractEventLoopPolicy `
37+ * :class: `!asyncio.DefaultEventLoopPolicy `
38+ * :class: `!asyncio.WindowsSelectorEventLoopPolicy `
39+ * :class: `!asyncio.WindowsProactorEventLoopPolicy `
40+ * :func: `!asyncio.get_event_loop_policy `
41+ * :func: `!asyncio.set_event_loop_policy `
42+
43+ Users should use :func: `asyncio.run ` or :class: `asyncio.Runner ` with
44+ *loop_factory * to use the desired event loop implementation.
45+
46+ For example, to use :class: `asyncio.SelectorEventLoop ` on Windows::
47+
48+ import asyncio
49+
50+ async def main():
51+ ...
52+
53+ asyncio.run(main(), loop_factory=asyncio.SelectorEventLoop)
54+
55+ (Contributed by Kumar Aditya in :gh: `127949 `.)
56+
3357* :mod: `builtins `:
3458
3559 * Bitwise inversion on boolean types, ``~True `` or ``~False ``
You can’t perform that action at this time.
0 commit comments