New submission from Tatsunosuke Shimada <adam.is.t...@gmail.com>:

BufferingHandler

I expected function flush of BufferingHandler called once but it is called 
twice. 
This is due to that shutdown calls flush before close function which calls 
flush function inside.
(Faced this issue on my custom implementation of flush function.)

Seems that there is no need of calling flush inside BufferingHandler.

Following is the link to the code of function shutdown and Buffering Handler
https://github.com/python/cpython/blob/0124f2b5e0f88ee7f5d40fca96dbf087cbe4764b/Lib/logging/handlers.py#L1286
https://github.com/python/cpython/blob/a74eea238f5baba15797e2e8b570d153bc8690a7/Lib/logging/__init__.py#L2151

This issue could be also related.
https://bugs.python.org/issue26559

----------
components: Library (Lib)
messages: 374559
nosy: adamist521, vinay.sajip
priority: normal
severity: normal
status: open
title: Logging libraries BufferingHandler flushed twice at shutdown
type: behavior
versions: Python 3.8

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue41433>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to