From e3ee9a299f6b66ba9afa7bd52eecfada64c85696 Mon Sep 17 00:00:00 2001 From: Pascal Vizeli Date: Mon, 17 Aug 2020 15:37:19 +0200 Subject: [PATCH] Send exception why the update fails (#1938) --- supervisor/core.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/supervisor/core.py b/supervisor/core.py index b3c81f28a..522e07664 100644 --- a/supervisor/core.py +++ b/supervisor/core.py @@ -164,7 +164,7 @@ class Core(CoreSysAttributes): # Check if system is healthy if not self.supported: _LOGGER.critical("System running in a unsupported environment!") - elif not self.healthy: + if not self.healthy: _LOGGER.critical( "System running in a unhealthy state and need manual intervention!" ) @@ -180,11 +180,12 @@ class Core(CoreSysAttributes): _LOGGER.warning("Ignore Supervisor updates!") else: await self.sys_supervisor.update() - except SupervisorUpdateError: + except SupervisorUpdateError as err: _LOGGER.critical( "Can't update supervisor! This will break some Add-ons or affect " "future version of Home Assistant!" ) + self.sys_capture_exception(err) # Start addon mark as initialize await self.sys_addons.boot(AddonStartup.INITIALIZE)