mirror of
https://github.com/smkrv/ha-text-ai.git
synced 2026-07-29 11:53:55 +08:00
Release v2.0.0
This commit is contained in:
@@ -204,7 +204,6 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
|||||||
else:
|
else:
|
||||||
raise ConfigEntryNotReady("Failed to connect to API")
|
raise ConfigEntryNotReady("Failed to connect to API")
|
||||||
|
|
||||||
# Create coordinator
|
|
||||||
try:
|
try:
|
||||||
# Create coordinator
|
# Create coordinator
|
||||||
coordinator = HATextAICoordinator(
|
coordinator = HATextAICoordinator(
|
||||||
@@ -237,6 +236,11 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
|||||||
_LOGGER.exception("Error initializing coordinator: %s", str(ex))
|
_LOGGER.exception("Error initializing coordinator: %s", str(ex))
|
||||||
raise ConfigEntryNotReady(f"Error initializing coordinator: {str(ex)}") from ex
|
raise ConfigEntryNotReady(f"Error initializing coordinator: {str(ex)}") from ex
|
||||||
|
|
||||||
|
except Exception as ex:
|
||||||
|
_LOGGER.exception("Setup error: %s", str(ex))
|
||||||
|
raise ConfigEntryNotReady(f"Setup error: {str(ex)}") from ex
|
||||||
|
|
||||||
|
|
||||||
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
||||||
"""Unload a config entry."""
|
"""Unload a config entry."""
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user