From 800de104a945411a2d022c3630cb932218565c3c Mon Sep 17 00:00:00 2001 From: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Date: Sun, 7 Jul 2024 12:15:34 +0200 Subject: [PATCH] Enable InlineTypedDict https://mypy.readthedocs.io/en/latest/typed_dict.html#inline-typeddict-types --- mypy.ini | 1 + script/hassfest/mypy_config.py | 8 +++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/mypy.ini b/mypy.ini index ce51adc3816259..43db8459972b20 100644 --- a/mypy.ini +++ b/mypy.ini @@ -8,6 +8,7 @@ platform = linux plugins = pydantic.mypy show_error_codes = true follow_imports = normal +enable_incomplete_feature = InlineTypedDict local_partial_types = true strict_equality = true no_implicit_optional = true diff --git a/script/hassfest/mypy_config.py b/script/hassfest/mypy_config.py index ec4d4b3d3a9d78..3f6420e6c81be5 100644 --- a/script/hassfest/mypy_config.py +++ b/script/hassfest/mypy_config.py @@ -36,9 +36,11 @@ "plugins": "pydantic.mypy", "show_error_codes": "true", "follow_imports": "normal", - # "enable_incomplete_feature": ", ".join( # noqa: FLY002 - # [] - # ), + "enable_incomplete_feature": ", ".join( # noqa: FLY002 + [ + "InlineTypedDict", + ] + ), # Enable some checks globally. "local_partial_types": "true", "strict_equality": "true",