fix linting

This commit is contained in:
Robert Kaussow 2024-01-15 15:14:18 +01:00
parent 5a90e3ee12
commit b537d330ce
Signed by: xoxys
GPG Key ID: 4E692A2EAECC03C0
1 changed files with 2 additions and 2 deletions

View File

@ -46,7 +46,7 @@ class LogFilter:
class MultilineFormatter(logging.Formatter):
"""Logging Formatter to reset color after newline characters."""
def format(self, record): # noqa
def format(self, record):
record.msg = record.msg.replace("\n", f"\n{colorama.Style.RESET_ALL}... ")
return logging.Formatter.format(self, record)
@ -54,7 +54,7 @@ class MultilineFormatter(logging.Formatter):
class MultilineJsonFormatter(jsonlogger.JsonFormatter):
"""Logging Formatter to remove newline characters."""
def format(self, record): # noqa
def format(self, record):
record.msg = record.msg.replace("\n", " ")
return jsonlogger.JsonFormatter.format(self, record)