Time input validation in automation UI #9552
Unanswered
tokyotexture
asked this question in
Automations / scripts / scenes
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I wanted to add a 5 minute "for" requirement for a numeric state trigger in automations, and UI will let me save values that aren't valid and makes automation fail silently. Very non-intuitive for people not familiar with digging into HA logs.
I'm used to writing yaml in the format of
for:
hours: 1
minutes: 10
seconds: 5
so I assumed that writing "5 minutes" in the "For" field in the automation UI would work. I was able to save the automation without errors, and had to go to the logs to figure out what happened when it didn't trigger.
I'm not sure if this should be an enhancement request or bug, but since it failed to parse without error, I'm inclined to say it's a bug. Obviously not a big deal to write "00:05", but UI is misleading/confusing. Why even have a text field if it's HH:MM:SS type input? I guess keeping it as a text field would be ok, assuming there's some validation, because I really thought I had a working automation when I saved it...
Beta Was this translation helpful? Give feedback.
All reactions