Merge pull request #2117 from InfinityPacer/main

fix 开启DEBUG时,LOG文件也记录DEBUG日志
This commit is contained in:
jxxghp 2024-05-19 12:28:08 +08:00 committed by GitHub
commit cf20049b7f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -109,7 +109,6 @@ class LoggerManager:
maxBytes=5 * 1024 * 1024, maxBytes=5 * 1024 * 1024,
backupCount=3, backupCount=3,
encoding='utf-8') encoding='utf-8')
file_handler.setLevel(logging.INFO)
file_formater = CustomFormatter(f"【%(levelname)s】%(asctime)s - %(message)s") file_formater = CustomFormatter(f"【%(levelname)s】%(asctime)s - %(message)s")
file_handler.setFormatter(file_formater) file_handler.setFormatter(file_formater)
_logger.addHandler(file_handler) _logger.addHandler(file_handler)