diff --git a/.strict-typing b/.strict-typing index 6b2c52f42f6..f59323ef76c 100644 --- a/.strict-typing +++ b/.strict-typing @@ -103,6 +103,7 @@ homeassistant.components.devolo_home_control.* homeassistant.components.devolo_home_network.* homeassistant.components.dhcp.* homeassistant.components.diagnostics.* +homeassistant.components.discovergy.* homeassistant.components.dlna_dmr.* homeassistant.components.dnsip.* homeassistant.components.doorbird.* diff --git a/homeassistant/components/discovergy/config_flow.py b/homeassistant/components/discovergy/config_flow.py index e035661db10..b3dee2d82a0 100644 --- a/homeassistant/components/discovergy/config_flow.py +++ b/homeassistant/components/discovergy/config_flow.py @@ -60,15 +60,6 @@ class ConfigFlow(config_entries.ConfigFlow, domain=DOMAIN): """Handle the initial step.""" self.existing_entry = await self.async_set_unique_id(self.context["unique_id"]) - if entry_data is None: - return self.async_show_form( - step_id="reauth", - data_schema=make_schema( - self.existing_entry.data[CONF_EMAIL] or "", - self.existing_entry.data[CONF_PASSWORD] or "", - ), - ) - return await self._validate_and_save(entry_data, step_id="reauth") async def _validate_and_save( diff --git a/homeassistant/components/discovergy/system_health.py b/homeassistant/components/discovergy/system_health.py index 2baeb0e5f6e..61fe4099596 100644 --- a/homeassistant/components/discovergy/system_health.py +++ b/homeassistant/components/discovergy/system_health.py @@ -1,4 +1,6 @@ """Provide info to system health.""" +from typing import Any + from pydiscovergy.const import API_BASE from homeassistant.components import system_health @@ -13,7 +15,7 @@ def async_register( register.async_register_info(system_health_info) -async def system_health_info(hass): +async def system_health_info(hass: HomeAssistant) -> dict[str, Any]: """Get info for the info page.""" return { "api_endpoint_reachable": system_health.async_check_can_reach_url( diff --git a/mypy.ini b/mypy.ini index c2ecac66946..94ad7cc018b 100644 --- a/mypy.ini +++ b/mypy.ini @@ -792,6 +792,16 @@ warn_return_any = true warn_unreachable = true no_implicit_reexport = true +[mypy-homeassistant.components.discovergy.*] +check_untyped_defs = true +disallow_incomplete_defs = true +disallow_subclassing_any = true +disallow_untyped_calls = true +disallow_untyped_decorators = true +disallow_untyped_defs = true +warn_return_any = true +warn_unreachable = true + [mypy-homeassistant.components.dlna_dmr.*] check_untyped_defs = true disallow_incomplete_defs = true