From c901352bef813c8faac18311a14b6e88d0ef7663 Mon Sep 17 00:00:00 2001
From: Erik Montnemery <erik@montnemery.com>
Date: Fri, 3 Jan 2025 10:01:35 +0100
Subject: [PATCH] Add error prints for recorder fatal errors (#134517)

---
 homeassistant/components/recorder/core.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/homeassistant/components/recorder/core.py b/homeassistant/components/recorder/core.py
index e027922e8c4..fee72ce273f 100644
--- a/homeassistant/components/recorder/core.py
+++ b/homeassistant/components/recorder/core.py
@@ -712,12 +712,14 @@ class Recorder(threading.Thread):
         setup_result = self._setup_recorder()
 
         if not setup_result:
+            _LOGGER.error("Recorder setup failed, recorder shutting down")
             # Give up if we could not connect
             return
 
         schema_status = migration.validate_db_schema(self.hass, self, self.get_session)
         if schema_status is None:
             # Give up if we could not validate the schema
+            _LOGGER.error("Failed to validate schema, recorder shutting down")
             return
         if schema_status.current_version > SCHEMA_VERSION:
             _LOGGER.error(
-- 
GitLab