mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 05:07:41 +00:00
Add sleep_period to log for easier debugging (#56949)
This commit is contained in:
parent
f42c2f5170
commit
62f1a16918
@ -320,9 +320,11 @@ class BlockDeviceWrapper(update_coordinator.DataUpdateCoordinator):
|
||||
|
||||
async def _async_update_data(self) -> None:
|
||||
"""Fetch data."""
|
||||
if self.entry.data.get("sleep_period"):
|
||||
if sleep_period := self.entry.data.get("sleep_period"):
|
||||
# Sleeping device, no point polling it, just mark it unavailable
|
||||
raise update_coordinator.UpdateFailed("Sleeping device did not update")
|
||||
raise update_coordinator.UpdateFailed(
|
||||
f"Sleeping device did not update within {sleep_period} seconds interval"
|
||||
)
|
||||
|
||||
_LOGGER.debug("Polling Shelly Block Device - %s", self.name)
|
||||
try:
|
||||
|
Loading…
x
Reference in New Issue
Block a user