feat: suppress healthcheck logs in dev mode

Reduce visual noise during development by logging healthcheck requests
at DEBUG level when DEPLOYMENT_MODE=DEV. Production mode continues to
log healthchecks at INFO level for proper observability.

Changes:
- Modified /health endpoint to check deployment mode
- DEV mode: logs at DEBUG level (only visible with DEBUG logging)
- PROD mode: logs at INFO level (maintains current behavior)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-03 21:58:36 -05:00
parent 0669bd1bab
commit 090875d6f2

View File

@@ -713,6 +713,14 @@ def create_app(
Returns:
Health status and timestamp
"""
from tools.deployment_config import is_dev_mode
# Log at DEBUG in dev mode, INFO in prod mode
if is_dev_mode():
logger.debug("Health check")
else:
logger.info("Health check")
try:
# Test database connection
conn = get_db_connection(app.state.db_path)