bpo-34037: Fix test_asyncio failure and add loop.shutdown_default_executor() (GH-15735)
diff --git a/Doc/library/asyncio-task.rst b/Doc/library/asyncio-task.rst
index 57e0e07..d932042 100644
--- a/Doc/library/asyncio-task.rst
+++ b/Doc/library/asyncio-task.rst
@@ -213,8 +213,8 @@
.. function:: run(coro, \*, debug=False)
This function runs the passed coroutine, taking care of
- managing the asyncio event loop and *finalizing asynchronous
- generators*.
+ managing the asyncio event loop, *finalizing asynchronous
+ generators*, and closing the threadpool.
This function cannot be called when another asyncio event loop is
running in the same thread.
@@ -229,6 +229,8 @@
**Important:** this function has been added to asyncio in
Python 3.7 on a :term:`provisional basis <provisional api>`.
+ .. versionchanged:: 3.9
+ Updated to use :meth:`loop.shutdown_default_executor`.
Creating Tasks
==============