Create new state property for alarm_control_panel
which is using an enum
#1140
-
BackgroundSome entity models (like ProposalSimilar to the @final
@cached_property
def state(self) -> str | None:
"""Return the current state."""
return alarm_state
@cached_property
def alarm_state(self) -> AlarmControlPanelEntityState | None:
"""Return the current alarm control panel entity state.
Integrations should overwrite this or use the 'attr_alarm_state'
attribute to set the alarm status using the 'AlarmControlPanelEntityState' enum.
"""
return self._attr_alarm_state After the deprecation period we would change property to be Draft conceptual PR:home-assistant/core#126283 Update after initial proposal
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
The |
Beta Was this translation helpful? Give feedback.
-
We've discussed this proposal in the Core team and decided to approve it. |
Beta Was this translation helpful? Give feedback.
We've discussed this proposal in the Core team and decided to approve it.