[issue28524] Set default argument of logging.disable() to logging.CRITICAL

Al Sweigart report at bugs.python.org
Mon Oct 24 23:35:11 EDT 2016


Al Sweigart added the comment:

> How about logger.disabled = True.

This seems to violate "there should be one and only one way to do it". What happens when logging.disabled is True but then logging.disable(logging.NOTSET) is called? I could see this being a gotcha.

Since logging.CRITICAL is 50, I think it's reasonable to assume that no one would create a logging level larger than sys.maxsize.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue28524>
_______________________________________


More information about the Python-bugs-list mailing list