home-assistant/core · warning · UpdateFailed

error_fetching_data

error_fetching_data

Error message

Error fetching data

What it means

Raised as UpdateFailed (translation_key error_fetching_data) by the aws_s3 S3DataUpdateCoordinator when listing backups from S3 (async_list_backups_from_s3) raises BotoCoreError. The sensor update fails gracefully and retries on the next coordinator interval.

Source

Thrown at homeassistant/components/aws_s3/coordinator.py:66

            hass,
            _LOGGER,
            config_entry=entry,
            name=DOMAIN,
            update_interval=SCAN_INTERVAL,
        )
        self.client = client
        self._bucket: str = entry.data[CONF_BUCKET]
        self._prefix: str = entry.data.get(CONF_PREFIX, "")

    @override
    async def _async_update_data(self) -> SensorData:
        """Fetch data from AWS S3."""
        try:
            backups = await async_list_backups_from_s3(
                self.client, self._bucket, self._prefix
            )
        except BotoCoreError as error:
            raise UpdateFailed(
                translation_domain=DOMAIN,
                translation_key="error_fetching_data",
            ) from error

        all_backups_size = sum(b.size for b in backups)
        return SensorData(
            all_backups_size=all_backups_size,
        )

View on GitHub (pinned to 58a3fdb3ea)

Solutions

  1. Check connectivity and credentials with aws s3 ls s3://<bucket>/<prefix> using the same keys.
  2. If keys were rotated, re-enter them via the integration's reconfigure/re-auth flow (setup validated them once; runtime may now fail).
  3. If the bucket was deleted or renamed, update the config entry accordingly.
  4. Transient network errors self-heal on the next coordinator refresh.
Defensive patterns

Strategy: fallback

Try / catch

from homeassistant.helpers.update_coordinator import UpdateFailed

try:
    data = await coordinator.async_refresh()
except UpdateFailed:
    data = coordinator.data  # serve last known sizes; sensor shows stale until next success

Prevention

When it happens

Trigger: The coordinator's periodic refresh calls list_objects_v2/GetObjects over the bucket prefix and boto3 raises: credentials invalidated since setup, endpoint unreachable, throttling, or bucket deleted.

Common situations: Access key deleted after setup worked; MinIO endpoint down; bucket removed; intermittent network to the storage backend.

Related errors


AI-assisted analysis of home-assistant/core@58a3fdb3ea (2026-08-14). Data as JSON: /api/errors/aa887864117acf6e. Report an issue: GitHub.