Can’t understand why “And If” is there when you can implement the same logic and better with the toolset available on “Then Do”.
Writing automations in HA can be a pain for newcomers as I.
It’s difficult to understand with an AND / OR is implicit, it’s difficult to understand parallelism, it’s difficult to follow the yaml since with the change from UI to YAML and vice versa, the code seams to move place. It’s difficult to debug.
I believe a lot of improvement could be done here.
Can’t say I’m not a fan of the simple NodeRED UI. Simple blocks linking to each other passing the action down to a reaction.
Just my thoughts on What The Heck.
Thank you all for the great work on HA!
Happy Holidays!
And if is used when you want something to only happen if certain conditions are met, such as only turning up the heat if there is someone in the house.
One reason to use the general conditions block… When all the conditions in the Conditions block (And If) pass, the last_triggered attribute gets set; if any of them fail, the attribute retains its previous value. This distinction allows us to create conditions that can throttle the rate of an automation based on that attribute instead of requiring delays or timers.
FWIW, I despise the renaming of the blocks to “When”, “And If”, “Then Do”… it doesn’t seem to have helped and it seems to have moved some new users further away from understanding the concepts behind automations in HA.