This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Make it explicit what happens when using a bounded queue with QueueHandler
Type: Stage: resolved
Components: Documentation Versions: Python 3.9, Python 3.8, Python 3.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: docs@python, mjpieters, vinay.sajip
Priority: normal Keywords: patch

Created on 2019-07-01 13:42 by mjpieters, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 14532 merged vinay.sajip, 2019-07-01 19:14
PR 14533 merged miss-islington, 2019-07-01 19:45
PR 14534 merged miss-islington, 2019-07-01 19:45
Messages (4)
msg347018 - (view) Author: Martijn Pieters (mjpieters) * Date: 2019-07-01 13:42
The documentation doesn't make it explicit what happens if you use a bounded queue together with logging.handlers.QueueHandler.

If the queue is bounded in size and attempts are made to add logrecords faster than a queue listener removes them, then the resulting `queue.Full` exception is passed to `handler.handleError()` and that usually means the record is simply dropped (see https://docs.python.org/3/library/logging.html#logging.Handler.handleError).

That may be the desired behaviour, but making it explicit is always better.
msg347069 - (view) Author: Vinay Sajip (vinay.sajip) * (Python committer) Date: 2019-07-01 19:45
New changeset 0f4e8132820947d93eccf31b9e526b81c6ffa53d by Vinay Sajip in branch 'master':
bpo-37470: Document more clearly the error handling for QueueHandler.emit(). (GH-14532)
https://github.com/python/cpython/commit/0f4e8132820947d93eccf31b9e526b81c6ffa53d
msg347071 - (view) Author: Vinay Sajip (vinay.sajip) * (Python committer) Date: 2019-07-01 19:51
New changeset 844a9d64a4f640d1b20dc6ea54ab375680332d93 by Vinay Sajip (Miss Islington (bot)) in branch '3.7':
bpo-37470: Document more clearly the error handling for QueueHandler.emit(). (GH-14532) (GH-14534)
https://github.com/python/cpython/commit/844a9d64a4f640d1b20dc6ea54ab375680332d93
msg347072 - (view) Author: Vinay Sajip (vinay.sajip) * (Python committer) Date: 2019-07-01 19:53
New changeset 91f9f098fcdb023dbb89d06c8833e89a11cbae4c by Vinay Sajip (Miss Islington (bot)) in branch '3.8':
bpo-37470: Document more clearly the error handling for QueueHandler.emit(). (GH-14532) (GH-14533)
https://github.com/python/cpython/commit/91f9f098fcdb023dbb89d06c8833e89a11cbae4c
History
Date User Action Args
2022-04-11 14:59:17adminsetgithub: 81651
2019-07-01 19:54:29vinay.sajipsetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2019-07-01 19:53:42vinay.sajipsetmessages: + msg347072
2019-07-01 19:51:24vinay.sajipsetmessages: + msg347071
2019-07-01 19:45:42miss-islingtonsetpull_requests: + pull_request14347
2019-07-01 19:45:35miss-islingtonsetpull_requests: + pull_request14346
2019-07-01 19:45:08vinay.sajipsetmessages: + msg347069
2019-07-01 19:14:27vinay.sajipsetkeywords: + patch
stage: patch review
pull_requests: + pull_request14345
2019-07-01 13:45:44xtreaksetnosy: + vinay.sajip
2019-07-01 13:42:59mjpieterscreate