diff --git a/snuba/utils/health_info.py b/snuba/utils/health_info.py index baeb00b965..fc80e74fac 100644 --- a/snuba/utils/health_info.py +++ b/snuba/utils/health_info.py @@ -107,10 +107,10 @@ def get_health_info(thorough: Union[bool, str]) -> HealthInfo: payload = json.dumps(body) if status != 200: metrics.increment("healthcheck_failed", tags=metric_tags) - logger.error(f"Snuba health check failed! Tags: {metric_tags}") - - if status != 200 or down_file_exists: - logger.info(payload) + if down_file_exists: + logger.error("Snuba health check failed! Tags: %s", metric_tags) + else: + logger.info("Snuba health check failed! Tags: %s", metric_tags) metrics.timing( "healthcheck.latency",