Repository navigation
Revise the standard button event types and their triggers and conditions #1502
SummaryThis proposal amends the approved proposal #1377 (standard event types for ProblemThe first trigger implementation, core#177683, stalled on a question the approved text does not answer, and the Matter (core#177101), isy994 (core#169782) and Lutron Caséta (core#184266) migrations each resolved it differently. #1377 defines
In the third shape the release and the single click are two events: the device reports the release immediately, and the single click only after its multi-press window has passed, because only then does it know there was no second press. Reading ProposalEvent typesThe event types form two layers that map onto the three shapes above. Physical types describe the edges of the button. Gesture types describe what the device concluded. A device declares a type in
Triggers and conditionsWhere a trigger lists fallbacks, it fires on the first type in the list that the entity declares, so the trigger means the same on every device and only the timing follows the hardware. Each trigger carries a static requirement on the entity's
Deferred, with the same model:
Rules for integrations
Indicative mappingThe table shows how the main sources would map under the rules above, based on protocol documentation and the current integration code. It is illustrative, not prescriptive: integration authors should verify how their devices actually report, in particular whether a hold arrives at the threshold or after release, before migrating. Click to expand
FrontendThe target selector needs to filter entities by the content of the Changes relative to #1377Click to expand
Out of scopeRotary input, as in #1377. Dials and wheels need their own device class and vocabulary. That includes the IKEA BILRESA wheel, which reaches Home Assistant as a Matter multi-press switch and was the only real consumer of |
Replies: 4 comments 3 replies
|
@arturpragacz thanks for writing this up! The proposed Lutron mapping matches what I tested on an RA3 system directly:
Happy to update home-assistant/core#184266 to this mapping once it's settled 😄 |
|
The previous proposal focused on a consistent logical model at the entity-level, with triggers consuming that directly. This one focuses on passing a bit more "raw" events from integrations, making the triggers work around them. I like the addition of the "physical" events, but I like the consistent "logical" events that the original proposal defined. I'm splitting the comment in the original proposal sections to make it easier to follow: Problem section
This part regarding the original proposal is not correct. In that proposal,
This assumption is also incorrect: Event types section
Triggers and conditions section
Rules for integrations section
This is another limitation that the previous proposal did not have. If the device only reports |
|
I will be commenting on the trigger/condition surface as the underlying event layer, while accessible to users, is not intended to be the primary surface for interacting with buttons in things like automations and scripts. I understand and support the reasoning behind changing the event surface. What I don't quite get is why the trigger/condition surface had to change with it.
I much prefer the approach @abmantis and I landed on in home-assistant/core#168598, which is to have a Furthermore, I don't quite understand the reasoning behind the renaming of I'm open to discussing how these names work together, but I think deferring the |
|
The proposal was approved by the core meeting 2026-10-15 |
The proposal was approved by the core meeting 2026-10-15