feat: Handle '/dev/stdout' in Logger Configuration

This commit is contained in:
gmailnovo
2023-12-07 11:27:45 +08:00
committed by GitHub
parent a4f65e7fc6
commit d3c87ee500

View File

@@ -192,6 +192,7 @@ def configure_logger(app):
app.logger.addHandler(handler)
log_file = app.config['LOG_PATH']
if log_file and log_file != "/dev/stdout":
file_handler = RotatingFileHandler(log_file,
maxBytes=2 ** 30,
backupCount=7)