diff --git a/homeassistant/components/button/__init__.py b/homeassistant/components/button/__init__.py index 6826f681d4d..10589aa461f 100644 --- a/homeassistant/components/button/__init__.py +++ b/homeassistant/components/button/__init__.py @@ -123,10 +123,8 @@ class ButtonEntity(RestoreEntity, cached_properties=CACHED_PROPERTIES_WITH_ATTR_ def __set_state(self, state: str | None) -> None: """Set the entity state.""" - try: # noqa: SIM105 suppress is much slower - del self.state - except AttributeError: - pass + # Invalidate the cache of the cached property + self.__dict__.pop("state", None) self.__last_pressed_isoformat = state @final