Wait for events happening faster than the wait time

Hi all,

I've been trying to adjust a rule machine rule to have the correct wait time before a light turns on.

Basically when my TV reports paused or stopped I want the lights to turn on, This has a paired rule where the light turn off when the TV is playing

I don't want the rule to run too quickly because then when ads or content load the lights flash on and off as the loading counts as paused.

Anyway I noticed that as I changed the wait time I didnt see the lights taking longer to turn on or off. So I checked my logs and found the "stayed" events were happening in less time than than the wait time. You can see in the log screenshot that the waiting event starts and then only a couple miliseconds later the wait is complete even though it says it is for 4 seconds. Rule is also attached.

Have I set up this rule wrong or have I encountered a bug?

Screenshot_20220819-214827

Have you tried adjusting the air time to see if the rule follows? Eg, if you bump it to 7 seconds does it only wait 5.

These logs don't appear to belong to this rule. At 09:47:29.658 the action is Rule Boolean False:... The posted rule has an action for True but not False. Also, 09:47:29.787 the action is Dim: LV_Lights: 0 which isn't in the rule.

However, the stays does take 4 seconds.
09:47:25.513 Event: waiting to stay for 0:00:04
09:47:29.539 Event: stayed for 0:00:04

Hey guys, thanks for your advice.

I tried changing the wait lengths and was still not getting consistent results.

I ended up restructuring the set of rules by removing the stays in the trigger and replacing them with wait actions and then cancellations of the waits in the "sister" rule (the off rule for the on and the on rule for the off). Appears to be working now.

Here are the new rules