修复了多重log
This commit is contained in:
parent
ccfaeac063
commit
2525dd5dcb
@ -20,7 +20,9 @@ logs = getLogger(__name__)
|
||||
logging_format = "%(levelname)s [%(asctime)s] [%(name)s] %(message)s"
|
||||
logging_handler = StreamHandler()
|
||||
logging_handler.setFormatter(ColoredFormatter(logging_format))
|
||||
logs.addHandler(logging_handler)
|
||||
root_logger = getLogger()
|
||||
root_logger.setLevel(logging.ERROR)
|
||||
root_logger.addHandler(logging_handler)
|
||||
basicConfig(level=INFO)
|
||||
logs.setLevel(INFO)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user