]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-65046: Link to logging cookbook from asyncio docs (GH-98207)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Wed, 12 Oct 2022 04:51:13 +0000 (21:51 -0700)
committerPablo Galindo <pablogsal@gmail.com>
Sat, 22 Oct 2022 19:04:42 +0000 (20:04 +0100)
(cherry picked from commit c39a0c335486fa8eac0f3030930f9e8769118a4f)

Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
Doc/howto/logging-cookbook.rst
Doc/library/asyncio-dev.rst

index 10639b15a47c9dc43a427107c54829e471e5f2bd..25ea37fc5ac9d46ea7e78a0819582b41b53d172e 100644 (file)
@@ -537,6 +537,8 @@ configuration::
     print('complete')
 
 
+.. _blocking-handlers:
+
 Dealing with handlers that block
 --------------------------------
 
index 77f1128de50c955122e7821cf81c6bfe7f0a4b8a..29d69b9f748d46f1671f822349561c2896c1806d 100644 (file)
@@ -148,6 +148,11 @@ adjusted::
    logging.getLogger("asyncio").setLevel(logging.WARNING)
 
 
+Network logging can block the event loop. It is recommended to use
+a separate thread for handling logs or use non-blocking IO. For example,
+see :ref:`blocking-handlers`.
+
+
 .. _asyncio-coroutine-not-scheduled:
 
 Detect never-awaited coroutines