1
0
mirror of https://github.com/home-assistant/core.git synced 2026-07-12 17:18:04 +01:00

Add debug logging with full exception details to legacy notify action in SMTP integration (#175781)

This commit is contained in:
Manu
2026-07-06 23:39:29 +02:00
committed by GitHub
parent 5a7b3054ed
commit 2ad15d7f3d
+6 -2
View File
@@ -321,13 +321,17 @@ class MailNotificationService(SmtpClient, BaseNotificationService):
break
except SMTPServerDisconnected:
_LOGGER.warning(
"SMTPServerDisconnected sending mail: retrying connection"
"SMTPServerDisconnected sending mail: retrying connection",
exc_info=_LOGGER.isEnabledFor(logging.DEBUG),
)
with suppress(SMTPException):
mail.quit()
mail = self.connect()
except SMTPException:
_LOGGER.warning("SMTPException sending mail: retrying connection")
_LOGGER.warning(
"SMTPException sending mail: retrying connection",
exc_info=_LOGGER.isEnabledFor(logging.DEBUG),
)
with suppress(SMTPException):
mail.quit()
mail = self.connect()