refactor(systemd): Slim down log output via RichHandler
This commit is contained in:
parent
98f6eb0ae0
commit
ce44e728e0
@ -84,7 +84,12 @@ logging.basicConfig(
|
|||||||
format=CONST.LOG_FORMAT,
|
format=CONST.LOG_FORMAT,
|
||||||
datefmt="[%X]",
|
datefmt="[%X]",
|
||||||
handlers=[RichHandler(
|
handlers=[RichHandler(
|
||||||
rich_tracebacks=True
|
show_time=False if any([systemd_env_var in os.environ for systemd_env_var in [
|
||||||
|
"SYSTEMD_EXEC_PID",
|
||||||
|
"INVOCATION_ID"]]) else True,
|
||||||
|
rich_tracebacks=True,
|
||||||
|
show_path=False,
|
||||||
|
show_level=False
|
||||||
)]
|
)]
|
||||||
)
|
)
|
||||||
log = logging.getLogger("rich")
|
log = logging.getLogger("rich")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user