diff --git a/homeassistant/components/homekit_controller/entity.py b/homeassistant/components/homekit_controller/entity.py index 136c063f280..c5478ccb97d 100644 --- a/homeassistant/components/homekit_controller/entity.py +++ b/homeassistant/components/homekit_controller/entity.py @@ -2,7 +2,6 @@ from __future__ import annotations -import contextlib from typing import Any from aiohomekit.model.characteristics import ( @@ -80,11 +79,7 @@ class HomeKitEntity(Entity): def _async_clear_property_cache(self, properties: tuple[str, ...]) -> None: """Clear the cache of properties.""" for prop in properties: - # suppress is slower than try-except-pass, but - # we do not expect to have many properties to clear - # or this to be called often. - with contextlib.suppress(AttributeError): - delattr(self, prop) + self.__dict__.pop(prop, None) @callback def _async_reconfigure(self) -> None: