Isn’t that what you would expect? If you mode restricted the first automation to Night, which includes the 2 minutes after turn-off, then it shouldn’t run that automation once it’s Daytime.
This has come up before. You need to separate the automations so that the turn-off after 2 minutes is not mode restricted.
As @bravenel said, that behavior is what I would expect.
You probably want to look at adding a Smart Lighting automation which is restricted by time between sunset and sunrise. In the old ST app, you would use Smart Nightlight (or something like that).
Dont see how. Yup I can create a separate rule using “Smart Lighting” that will turn off the light when I close the door but notturn off light 15 minutes after I close door.
Ok, I found the screen you shown above however this option is only available when you Turn On a light via Open and Off after specified minutes which will only activate during a specific mode. If the mode changes before the time expires the light do not shut off.
That’s because you are using the turn off. In his picture @smart is using the app to turn on and off. When you do that, you can set a delay to turn off after x minutes. If you only use the app to turn off, you don’t get the delay
Please read my 1st post. My rule is turn on when door opens, turn off 15 minutes after door closes. Latter will not work if the mode changes before the 15 minutes have expired.
I get what your concern is, I was responding to your comment about Android app being different, which is not. However, back to your main concern, if you don’t want your sensor activated lights to stay on in certain modes, then when you run your routine you need to turn that light off. So in your example, when the mode changes to Daytime, you need to turn off that light. You may be off by a minute or two, but your lights won’t stay on all day.
Following bravenel’s advise, I came a separate rule. Basically, if the door closes during Daytime, turn off light immediately. That should be fine in most cases. What I am not sure of is if the door closes 5-14 minutes BEFORE the mode switch will the lights turn off 10-1 minutes into the new mode?
Not if the automation is mode restricted to Night. Whatever automation is going to turn the lights off, x minutes after the door closes, cannot be mode restricted to Night.
Mode restrictions are, for a good reason, strict in their interpretation. I know this from writing code that handles this case. Watcha gonna do? If the mode isn’t right, don’t execute whatever it is. So, anything put under a mode restriction is ONLY going to happen in that mode. If a single automation is mode restricted to Night, but turns something off x minutes after some event, it will only run if the mode is Night.