#Notify when automations fails to run
1 messages · Page 1 of 1 (latest)
did it fail to trigger or did it fail to do something after triggering?
After the trigger
The trigger works fine, but after that it ran into issues and failed to execute the rest of the automation
you are probably better off fixing the edge case.
however you could I guess do something like:
run a paralell
then inside that you run your usual stuff in a sequence
then seperatly running in paralell you have a sequence that waits for your last thing to happen. e.g. heating on entity changes. then you could have a timeout on that wait. so if after 5 minutes it hasnt triggered you could send an alert.
this feels hacky though
Fyi, node red can do it https://stevesnoderedguide.com/handling-errors-in-node-red-flows
A look at how to catch errors using the catch node in your flows so that you can take action in response to an error condition.
Thanks @swift gust and @wanton ocean. I'll give both a try.
You can do this natively in HA. If you set the following in your config, you can trigger off entries to your system log:
system_log:
fire_event: true
That then allows you to create an automation with the following trigger:
triggers:
- trigger: event
event_type: system_log_event
event_data:
name: homeassistant.components.automation
level: WARNING
The details are documented here: https://www.home-assistant.io/integrations/system_log/#events