mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 03:07:37 +00:00
Log cannot connect exception in Tedee config flow (#113740)
log exception
This commit is contained in:
parent
8918eb6922
commit
eaf86ee1ea
@ -1,6 +1,7 @@
|
||||
"""Config flow for Tedee integration."""
|
||||
|
||||
from collections.abc import Mapping
|
||||
import logging
|
||||
from typing import Any
|
||||
|
||||
from pytedee_async import (
|
||||
@ -18,6 +19,8 @@ from homeassistant.helpers.aiohttp_client import async_get_clientsession
|
||||
|
||||
from .const import CONF_LOCAL_ACCESS_TOKEN, DOMAIN, NAME
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class TedeeConfigFlow(ConfigFlow, domain=DOMAIN):
|
||||
"""Handle a config flow for Tedee."""
|
||||
@ -47,7 +50,8 @@ class TedeeConfigFlow(ConfigFlow, domain=DOMAIN):
|
||||
errors[CONF_LOCAL_ACCESS_TOKEN] = "invalid_api_key"
|
||||
except TedeeClientException:
|
||||
errors[CONF_HOST] = "invalid_host"
|
||||
except TedeeDataUpdateException:
|
||||
except TedeeDataUpdateException as exc:
|
||||
_LOGGER.error("Error during local bridge discovery: %s", exc)
|
||||
errors["base"] = "cannot_connect"
|
||||
else:
|
||||
if self.reauth_entry:
|
||||
|
Loading…
x
Reference in New Issue
Block a user