WTH do I have to specify a From/To in a state trigger in order to use "For"?

When I want an automation to trigger when an entity’s state remains constant for, say, 10 seconds, I’d like to be able to write this:

automation:
  trigger:
    platform: state
    entity_id: device_tracker.donka_phone
    for: "00:00:10"
  #...

In my mind, this should trigger when the device is set to “Away” or “Home” (or anything else) for 10 seconds.

Currently, however, Home Assistant throws an error if you try to specify a for: duration without a “From” or a “To”.

You can add multiple triggers with every From/To permutation, but it’s annoying. Particularly if you ever need to change the duration to something else.

Duplicate.

1 Like

Thank you. I’ve flagged my post for removal.