Author redstone-cold
Recipients docs@python, redstone-cold
Date 2016-12-29.16:29:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1483028994.58.0.687650973528.issue29105@psf.upfronthosting.co.za>
In-reply-to
Content
For 
class logging.handlers.RotatingFileHandler(filename, mode='a', maxBytes=0, backupCount=0, encoding=None, delay=0) 

if backupCount is zero and maxBytes is non-zero, the log file size could exceed maxBytes, i.e. we are not able to restrict the log file size using RotatingFileHandler at this case .
I suggest add the above description to the doc 
https://docs.python.org/3.6/library/logging.handlers.html#logging.handlers.RotatingFileHandler
If possible , set backupCount=1 by default to avoid this pitfall as much as possible.

The doc right now just says "if either of maxBytes or backupCount is zero, rollover never occurs.", it is too difficult to understand the meaning of 'Rollover' to aviod the pitfall .
History
Date User Action Args
2016-12-29 16:29:54redstone-coldsetrecipients: + redstone-cold, docs@python
2016-12-29 16:29:54redstone-coldsetmessageid: <1483028994.58.0.687650973528.issue29105@psf.upfronthosting.co.za>
2016-12-29 16:29:54redstone-coldlinkissue29105 messages
2016-12-29 16:29:54redstone-coldcreate