Node Red flow being triggered by HA restart

I have a fairly simple flow that is triggered by a change in state of a momentarty-action switch in my kitchen which turns off everything in the back of the house. However, this flow is being triggered by a restart of HA, which causes great confusion when I forget and reboot my NUC!

To get around this, I tried using sensor.ha_uptime and if it’s less than 10 minutes, I block the flow. However, this does not work so I wonder does anyone have a better solution?

Instead of using an events:state on the uptime, add a Current State node that checks your sensor.ha_uptime and make sure the state type is Number.

Here is a flow I have that checks the uptime.

My uptime node is:

and my switch is:

Hope this helps!

1 Like

Thanks Scott, that worked!