Modified files
storeapi/logging_conf.py
---
+++
@@ -20,6 +20,11 @@
if "email" in record.__dict__:
record.email = obfuscated(record.email, self.obfuscated_length)
return True
+
+
+handlers = ["default", "rotating_file"]
+if config.ENV_STATE == "prod":
+ handlers = ["default", "rotating_file", "logtail"]
def configure_logging() -> None:
@@ -81,7 +86,7 @@
"loggers": {
"uvicorn": {"handlers": ["default", "rotating_file"], "level": "INFO"},
"storeapi": {
- "handlers": ["default", "rotating_file", "logtail"],
+ "handlers": handlers,
"level": "DEBUG" if isinstance(config, DevConfig) else "INFO",
"propagate": False,
},