{"record":{"id":"bd7b69b04a4232d9","repo":"home-assistant/core","slug":"invalid-samba-password","errorCode":null,"errorMessage":"Invalid Samba password","messagePattern":"Invalid Samba password","errorType":"exception","errorClass":"ConfigEntryAuthFailed","httpStatus":null,"severity":"error","filePath":"homeassistant/components/airvisual_pro/coordinator.py","lineNumber":68,"sourceCode":"            LOGGER,\n            config_entry=config_entry,\n            name=\"Node/Pro data\",\n            update_interval=UPDATE_INTERVAL,\n        )\n        self._node = node\n        self.reload_task: asyncio.Task[bool] | None = None\n\n    @override\n    async def _async_update_data(self) -> dict[str, Any]:\n        \"\"\"Get data from the device.\"\"\"\n        try:\n            data = await self._node.async_get_latest_measurements()\n            data[\"history\"] = {}\n            if data[\"settings\"].get(\"follow_mode\") == \"device\":\n                history = await self._node.async_get_history(include_trends=False)\n                data[\"history\"] = history.get(\"measurements\", [])[-1]\n        except InvalidAuthenticationError as err:\n            raise ConfigEntryAuthFailed(\"Invalid Samba password\") from err\n        except NodeConnectionError as err:\n            if self.reload_task is None:\n                self.reload_task = self.hass.async_create_task(\n                    self.hass.config_entries.async_reload(self.config_entry.entry_id)\n                )\n            raise UpdateFailed(f\"Connection to Pro unit lost: {err}\") from err\n        except NodeProError as err:\n            raise UpdateFailed(f\"Error while retrieving data: {err}\") from err\n\n        return data\n","sourceCodeStart":50,"sourceCodeEnd":79,"githubUrl":"https://github.com/home-assistant/core/blob/58a3fdb3ea0538617f0a07efcfba6294de64fd59/homeassistant/components/airvisual_pro/coordinator.py#L50-L79","documentation":"ConfigEntryAuthFailed raised by the AirVisual Pro coordinator when the Samba connection to the Pro unit rejects the stored credentials (InvalidAuthenticationError). The Pro unit exposes data over SMB file shares, so wrong username/password marks the entry as needing re-authentication rather than retrying.","triggerScenarios":"async_get_latest_measurements() raises InvalidAuthenticationError: the Samba username/password in the config entry do not match an account on the AirVisual Pro unit, or the unit's SMB server requires different credentials after a firmware change.","commonSituations":"Pro unit credentials changed or reset (factory reset restores defaults), password typo at setup that only surfaces at first poll, or firmware updates altering SMB auth modes (e.g. dropping guest access or NTLM versions).","solutions":["Verify the Samba credentials by opening the unit's share from another machine.","Use the re-configuration flow in Home Assistant to re-enter username/password.","After a factory reset, update the entry with the new default credentials.","Ensure the firmware's SMB auth mode (NTLMv1/v2) is compatible — check unit settings."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":"def is_airvisual_pro_auth_failed(err: Exception) -> bool:\n    return isinstance(err, ConfigEntryAuthFailed) and \"Samba\" in str(err)","tryCatchPattern":"try:\n    await coordinator.async_refresh()\nexcept ConfigEntryAuthFailed:\n    # Samba credentials rejected: re-enter via re-auth flow; retries with same creds will keep failing\n    await hass.config_entries.async_reload(entry.entry_id)","preventionTips":["Test Samba access to the Pro unit's share from a PC before adding the integration.","Re-enter credentials in Home Assistant immediately after changing them on the unit.","After a factory reset, expect default credentials to apply and update the entry."],"tags":["home-assistant","airvisual-pro","samba","authentication"],"backgroundTag":null,"analyzedSha":"58a3fdb3ea0538617f0a07efcfba6294de64fd59","analyzedAt":"2026-08-14T20:54:38.818Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}