logging: Allow logging.exception helper to handle tracebacks.

Although `Logger.exception` supports passing exception info with
`exc_info`, when you use `logging.exception` keyword arguments are not
forwarded to the root logger, which makes passing `exc_info` raise
`TypeError`.

Signed-off-by: Nick Budak <thatbudakguy@gmail.com>
pull/1020/head
Nick Budak 2025-06-04 14:41:33 -07:00 zatwierdzone przez Damien George
rodzic 15a6233d04
commit 6e24cffe95
2 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -202,8 +202,8 @@ def critical(msg, *args):
getLogger().critical(msg, *args)
def exception(msg, *args):
getLogger().exception(msg, *args)
def exception(msg, *args, exc_info=True):
getLogger().exception(msg, *args, exc_info=exc_info)
def shutdown():

Wyświetl plik

@ -1,3 +1,3 @@
metadata(version="0.6.1")
metadata(version="0.6.2")
module("logging.py")