{"record":{"id":"8d1cf156b3071921","repo":"home-assistant/core","slug":"could-not-fetch-integration-list","errorCode":null,"errorMessage":"Could not fetch integration list","messagePattern":"Could not fetch integration list","errorType":"exception","errorClass":"ConfigEntryNotReady","httpStatus":null,"severity":"error","filePath":"homeassistant/components/analytics_insights/__init__.py","lineNumber":42,"sourceCode":"\n@dataclass(frozen=True)\nclass AnalyticsInsightsData:\n    \"\"\"Analytics data class.\"\"\"\n\n    coordinator: HomeassistantAnalyticsDataUpdateCoordinator\n    names: dict[str, str]\n\n\nasync def async_setup_entry(\n    hass: HomeAssistant, entry: AnalyticsInsightsConfigEntry\n) -> bool:\n    \"\"\"Set up Homeassistant Analytics from a config entry.\"\"\"\n    client = HomeassistantAnalyticsClient(session=async_get_clientsession(hass))\n\n    try:\n        integrations = await client.get_integrations(Environment.NEXT)\n    except HomeassistantAnalyticsConnectionError as ex:\n        raise ConfigEntryNotReady(\"Could not fetch integration list\") from ex\n\n    names = {}\n    for integration in entry.options[CONF_TRACKED_INTEGRATIONS]:\n        if integration not in integrations:\n            names[integration] = integration\n            continue\n        names[integration] = integrations[integration].title\n\n    coordinator = HomeassistantAnalyticsDataUpdateCoordinator(hass, entry, client)\n\n    await coordinator.async_config_entry_first_refresh()\n\n    entry.runtime_data = AnalyticsInsightsData(coordinator=coordinator, names=names)\n\n    await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)\n\n    return True\n","sourceCodeStart":24,"sourceCodeEnd":60,"githubUrl":"https://github.com/home-assistant/core/blob/58a3fdb3ea0538617f0a07efcfba6294de64fd59/homeassistant/components/analytics_insights/__init__.py#L24-L60","documentation":"Raised as ConfigEntryNotReady when client.get_integrations(Environment.NEXT) fails with HomeassistantAnalyticsConnectionError during setup of the analytics_insights integration. The Home Assistant Analytics insights web service (analytics.next.home-assistant.io) could not be reached, so the first fetch of the integration list failed and setup will be retried.","triggerScenarios":"async_setup_entry constructs HomeassistantAnalyticsClient and immediately calls get_integrations(Environment.NEXT); any connection error (DNS, TLS, timeout, HTTP 5xx) from that call maps to HomeassistantAnalyticsConnectionError.","commonSituations":"No internet on the HA host at setup time, the analytics insights service being down, or corporate firewalls/DNS filters blocking analytics.next.home-assistant.io.","solutions":["Verify outbound HTTPS to https://analytics.next.home-assistant.io from the HA host.","Wait for automatic retry — ConfigEntryNotReady schedules re-setup with backoff.","If a firewall blocks it, allowlist the analytics domain or remove the integration if the network policy forbids it.","Check the chained exception (__cause__) in logs for the precise network failure."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"except ConfigEntryNotReady: allow backoff retries; check connectivity if it persists past ~10 minutes.","preventionTips":["Set the entry up while the host has working internet.","Firewall/allowlist analytics.next.home-assistant.io if the network filters egress."],"tags":["network","analytics","retry","config-entry-not-ready"],"backgroundTag":null,"analyzedSha":"58a3fdb3ea0538617f0a07efcfba6294de64fd59","analyzedAt":"2026-08-14T20:54:38.818Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}