From 374255ce878d333e834516abc4d20b2bf879917f Mon Sep 17 00:00:00 2001 From: Maikel Punie Date: Thu, 27 Jul 2023 16:00:27 +0200 Subject: [PATCH] Duotecno beta fix (#97325) * Fix duotecno * Implement comments * small cover fix --- homeassistant/components/duotecno/__init__.py | 2 +- homeassistant/components/duotecno/cover.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/homeassistant/components/duotecno/__init__.py b/homeassistant/components/duotecno/__init__.py index 668a38dae5b..98003c3e8c4 100644 --- a/homeassistant/components/duotecno/__init__.py +++ b/homeassistant/components/duotecno/__init__.py @@ -22,10 +22,10 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool: await controller.connect( entry.data[CONF_HOST], entry.data[CONF_PORT], entry.data[CONF_PASSWORD] ) - await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS) except (OSError, InvalidPassword, LoadFailure) as err: raise ConfigEntryNotReady from err hass.data.setdefault(DOMAIN, {})[entry.entry_id] = controller + await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS) return True diff --git a/homeassistant/components/duotecno/cover.py b/homeassistant/components/duotecno/cover.py index 13e3df8fc0a..0fd212df085 100644 --- a/homeassistant/components/duotecno/cover.py +++ b/homeassistant/components/duotecno/cover.py @@ -26,7 +26,7 @@ async def async_setup_entry( """Set up the duoswitch endities.""" cntrl = hass.data[DOMAIN][entry.entry_id] async_add_entities( - DuotecnoCover(channel) for channel in cntrl.get_units("DuoSwitchUnit") + DuotecnoCover(channel) for channel in cntrl.get_units("DuoswitchUnit") )