Fix #1470.
This commit is contained in:
parent
1f800bf49a
commit
356808b02c
|
@ -141,7 +141,7 @@ def setupLogger(level="error", filename=None, filemode="w"):
|
||||||
if logging.getLoggerClass() is not Logging:
|
if logging.getLoggerClass() is not Logging:
|
||||||
logging.setLoggerClass(Logging)
|
logging.setLoggerClass(Logging)
|
||||||
|
|
||||||
level = levels.get(level, "error")
|
level = levels.get(level, logging.ERROR)
|
||||||
|
|
||||||
rootLogger = logging.getLogger()
|
rootLogger = logging.getLogger()
|
||||||
|
|
||||||
|
@ -162,6 +162,7 @@ def setupLogger(level="error", filename=None, filemode="w"):
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
handler = logging.StreamHandler()
|
handler = logging.StreamHandler()
|
||||||
|
|
||||||
handler.setLevel(level)
|
handler.setLevel(level)
|
||||||
|
|
||||||
formatter = logging.Formatter(
|
formatter = logging.Formatter(
|
||||||
|
|
Loading…
Reference in New Issue