Rules stop getting triggered?

So, recently I am seeing rules basically stop getting triggered. I have started to notice a trend but not really had time to figure it all out. One area I see mentioned is the use of the 'ignore triggers while executing' flag. I HAVE THIS ON in all cases I have seen so far.

If I run the actions manually they all run as expected.

Here is a simple rule that is now in this state.

This rule has been running basically since I got Habitat. I rewrote it (I was thinking maybe the rule is corrupt somehow). Ran for a few days then stopped tonight. As you can see is SHOULD run every hour, even if for some reason the sunset/sunrise don't trigger. I ran in manually, worked fine. Then I triggered it by switching the nighttime switch. It WAS triggered this time???

The logs show absolutely nothing when its not running. Basically, like there was no trigger. So yeah, not triggering for some odd reason. And I have seen a few other rules behaving in a similar manner -- again with this flag ON.

Any ideas on what it might be or where I might start digging?

Running a C8 Pro (which by the way is schweeet).

So I just also say a trigger NOT happen from an even simpler rule -- the 'ignore triggers' was NOT on. So, not that probably ... Sigh.

I'm not sure where to begin, but the fact that your actions are to turn Night On/Off, but one of your triggers is Night Changed doesn't seem like a good idea to me.

Maybe I'm wrong, but that strikes me as problematic.

2 Likes

Is there anything cut off, like a required expression?

Did you hit "Done" or "Update Rule" after adding or editing the trigger events (this is necessary to save)?

And while your rule should work either way, is there a reason you're using the "Ignore triggers while..." flag? Your rule is very short with no delays, waits, or anything else that should make it "run" for very long -- it looks to be a quick conditional check, then turning on or off a switch and sending a notification. There's nothing that this option would really do for you in this rule, and if anything, without any delays, waits, etc., if there is a problem, it might be some race condition regarding setting and un-setting this flag (a total guess without anything else to go on and hypothesized entirely from the fact that, again, your actions would effectively start and end within milliseconds).

EDIT: The above is also a good guess.

1 Like

Yeah, I could see that maybe causing issues. Although until now it has not. The reason that trigger is there is to make sure this switch stays in the correct state (so if it's turned off when it's not supposed to be, it turned back on).

Honestly, probably overkill.

The main reason was that I did not want the change it made to re-trigger the rule (the 2nd iteration would have done nothing). But not really needed.

Ok, I'll remove that trigger (on the switch) and the flag as neither are really needed for this to work ok. see if it all goes away. AND the only way anyone is changing the 'switch' is via sharp tools which I have as 'view only'.

I am wondering if maybe the C8 Pro update has changed timing from my previous C7 and these things you are all pointing out might have been fine before ... Let.s see.

Thanks for everyone's input. Multiple pairs of eyes are always helpful. I'll report back!

Why not just have two triggers, Sunrise and Sunset, then have it toggle the switch and notify you of the device state change. (or, Change the switch with an if statement and notify you of the device state. )

I did something similar with a rotating wake up alarm routine for my wife when she worked on Alternate Sundays/Saturdays each week.