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.

Author xmorel
Recipients OverLordGoldDragon, asvetlov, mbussonn, xmorel, yselivanov
Date 2020-12-15.18:19:47
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1608056387.56.0.811206723341.issue42644@roundup.psfhosted.org>
In-reply-to
Content
> I think that patching logging.disable to raise a type error immediately would be welcome

FWIW `logging` has a built-in checker / converter[0] which is already used in a bunch of places (e.g. the aforementioned setLevel), it could just be added inside `disable` in the same way it's used in setLevel[1] and would uniformly convert "level names" to proper levels or raise an error. That seems like a really easy patch / contribution.

[0] https://github.com/python/cpython/blob/3.9/Lib/logging/__init__.py#L189

[1] https://github.com/python/cpython/blob/3.9/Lib/logging/__init__.py#L906
History
Date User Action Args
2020-12-15 18:19:47xmorelsetrecipients: + xmorel, asvetlov, yselivanov, mbussonn, OverLordGoldDragon
2020-12-15 18:19:47xmorelsetmessageid: <1608056387.56.0.811206723341.issue42644@roundup.psfhosted.org>
2020-12-15 18:19:47xmorellinkissue42644 messages
2020-12-15 18:19:47xmorelcreate