|
@@ -342,7 +342,6 @@ async def _test_api_connection(hass: Any, base_url: str, token: str) -> None:
|
|
|
async with session.get(url, headers={"Authorization": f"Bearer {token}"}) as resp:
|
|
async with session.get(url, headers={"Authorization": f"Bearer {token}"}) as resp:
|
|
|
if resp.status in (401, 403):
|
|
if resp.status in (401, 403):
|
|
|
raise _ApiAuthError(f"HTTP {resp.status}")
|
|
raise _ApiAuthError(f"HTTP {resp.status}")
|
|
|
- resp.raise_for_status()
|
|
|
|
|
except _ApiAuthError:
|
|
except _ApiAuthError:
|
|
|
raise
|
|
raise
|
|
|
except Exception as exc:
|
|
except Exception as exc:
|