home-assistant/core · warning · UpdateFailed
err
Error message
err
What it means
In the Awair cloud coordinator, any non-auth exception raised while fetching the user, device list, or air data inside the timeout window is re-raised as UpdateFailed(err). This is the catch-all for rate limits, HTTP 5xx, malformed responses, and asyncio.TimeoutError from async with timeout(API_TIMEOUT). AuthError is handled separately as ConfigEntryAuthFailed (no message).
Source
Thrown at homeassistant/components/awair/coordinator.py:99
super().__init__(hass, config_entry, UPDATE_INTERVAL_CLOUD)
@override
async def _async_update_data(self) -> dict[str, AwairResult]:
"""Update data via Awair client library."""
async with timeout(API_TIMEOUT):
try:
LOGGER.debug("Fetching users and devices")
user = await self._awair.user()
devices = await user.devices()
results = await gather(
*(self._fetch_air_data(device) for device in devices)
)
return {result.device.uuid: result for result in results}
except AuthError as err:
raise ConfigEntryAuthFailed from err
except Exception as err:
raise UpdateFailed(err) from err
class AwairLocalDataUpdateCoordinator(AwairDataUpdateCoordinator):
"""Define a wrapper class to update Awair data from the local API."""
_device: AwairLocalDevice | None = None
def __init__(
self,
hass: HomeAssistant,
config_entry: AwairConfigEntry,
session: ClientSession,
) -> None:
"""Set up the AwairLocalDataUpdateCoordinator class."""
self._awair = AwairLocal(
session=session, device_addrs=[config_entry.data[CONF_HOST]]
)
View on GitHub (pinned to 58a3fdb3ea)
Solutions
- If transient (rate limit/outage), wait — UpdateFailed just delays the next refresh.
- Increase the integration's scan interval to reduce API pressure (many devices x frequent polls triggers 429).
- For local devices, switch to the local API config entry (AwairLocalDataUpdateCoordinator) which bypasses the cloud.
- If timeouts dominate, check network latency from HA to the Awair API.
Defensive patterns
Strategy: fallback
Try / catch
from homeassistant.helpers.update_coordinator import UpdateFailed, DataUpdateCoordinator
try:
data = await coordinator.async_refresh()
except UpdateFailed as err:
# keep last good coordinator.data; entities stay stale, not unavailable
data = coordinator.data Prevention
- Prefer the local API for Awair devices on the same LAN — fewer cloud failure modes.
- Keep scan intervals modest to stay under Awair cloud rate limits.
- Distinguish auth failures (ConfigEntryAuthFailed) from generic UpdateFailed before troubleshooting.
When it happens
Trigger: Calls to self._awair.user(), user.devices(), or parallel _fetch_air_data(device) tasks raise aiohttp/awair library errors; or the whole batch exceeds API_TIMEOUT; or the Awair cloud API returns 429/500.
Common situations: Awair API rate limiting (too many devices polled per scan interval); Awair cloud outage; slow network causing timeout; expired/invalid token surfacing as a generic error rather than AuthError.
Related errors
- api_error
- Error communicating with API: {err}
- Error communicating with API: {err}
- Unable find multi-factor auth module: {mfa_module_id}
- current_conditions_update_error
AI-assisted analysis of home-assistant/core@58a3fdb3ea (2026-08-14).
Data as JSON: /api/errors/d1cdb221093d60d4.
Report an issue: GitHub.