From d5c26aece1eec91fb3928acbf6ec04acd2fd63aa Mon Sep 17 00:00:00 2001 From: jan iversen Date: Mon, 23 Aug 2021 21:30:04 +0200 Subject: [PATCH] Activate mypy for tuya (#55057) --- homeassistant/components/tuya/config_flow.py | 5 ++++- mypy.ini | 3 --- script/hassfest/mypy_config.py | 1 - 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/homeassistant/components/tuya/config_flow.py b/homeassistant/components/tuya/config_flow.py index 970a1c54f1ef..476a2295fc42 100644 --- a/homeassistant/components/tuya/config_flow.py +++ b/homeassistant/components/tuya/config_flow.py @@ -1,5 +1,8 @@ """Config flow for Tuya.""" +from __future__ import annotations + import logging +from typing import Any from tuyaha import TuyaApi from tuyaha.tuyaapi import ( @@ -155,7 +158,7 @@ class OptionsFlowHandler(config_entries.OptionsFlow): """Initialize options flow.""" self.config_entry = config_entry self._conf_devs_id = None - self._conf_devs_option = {} + self._conf_devs_option: dict[str, Any] = {} self._form_error = None def _get_form_error(self): diff --git a/mypy.ini b/mypy.ini index c0495cd5c4cf..f425c3179edd 100644 --- a/mypy.ini +++ b/mypy.ini @@ -1640,9 +1640,6 @@ ignore_errors = true [mypy-homeassistant.components.tplink.*] ignore_errors = true -[mypy-homeassistant.components.tuya.*] -ignore_errors = true - [mypy-homeassistant.components.unifi.*] ignore_errors = true diff --git a/script/hassfest/mypy_config.py b/script/hassfest/mypy_config.py index ef681cc5ea34..a8b26b8c6f56 100644 --- a/script/hassfest/mypy_config.py +++ b/script/hassfest/mypy_config.py @@ -139,7 +139,6 @@ IGNORED_MODULES: Final[list[str]] = [ "homeassistant.components.todoist.*", "homeassistant.components.toon.*", "homeassistant.components.tplink.*", - "homeassistant.components.tuya.*", "homeassistant.components.unifi.*", "homeassistant.components.upnp.*", "homeassistant.components.vera.*",