I've had a lot of inconsistency with this app. Finally signed up for remote admin because it usually decides not to work when I leave town for a few days so I'm unable to evaluate the logs. Looks like it stops at the "Wait For Expression" point but never continues. Attached screenshots of the app code and log. The screenshot of the log was taken about 40 minutes after the app fired.
What release are you on? There was a bug fix for this recently.
2.3.4.139
The final action in the logs, Wait for Expression with Duration, will wait indefinitely until the expression is true and remains true for 15:00. It doesn't time out. So why wouldn't it just wait indefinitely?
I can't tell if you have all logging on or not, it doesn't look like it (Events, Triggers and Actions). There are no events after that Wait, so its state isn't going to change until there is a Motion Inactive event on one of the two sensors -- which based on the logs never happened. Hence, it waits...
What I can't figure out is why it didn't continue 15 minutes after both motion sensors went inactive.
In the logs it says False. So I'd imagine one of those sensors didn't report inactive. Notice also in the logs that Kitchen Motion Sensor reports active at 11:39, but never reports inactive. That's why.
The logs for both motion sensors show they reported inactive shortly after I left the apartment.
But not the app. What matters is that an event reached the app.
We should check one critical thing: When it gets to a Wait, there should be Event Subscriptions created for the conditions of the expression. These can be observed in the Event Subscription section of the App Status page (gear icon). So, if these motion inactive subscriptions didn't come into existence, that would both explain your issue, and be a bug. Those subscriptions go away once the wait is over -- they are transient and only present during the wait. That's something for you to check.
These would look like this:
I created a small rule with the same wait as yours, and it does create the correct subscriptions. With Event Logging on, an event will log, like the one in your logs above:
Here's my rule when both motion sensors go inactive;:
Here are the event subscriptions:
I also looked to see how the app behaved earlier in the day when I was home but not triggering those motion sensors. It appears like it was working the way it should, sensing that motion stayed inactive for 15 minutes and continuing on with the rest of the code:
This app is triggered anytime motion is sensed from either sensor (they basically cover different sides of one large room as the kitchen is open to the living room). So if I'm walking aroun,d this app is probably getting triggered a lot. Is it then just getting overloaded somehow?
Not likely. If it works during the day, why not at other times? What type of devices are these sensors?
The kitchen motion sensor is Xiaomi. The living room motion sensor is Phillips Hue.
I do get occasional false motion readings from the Xiaomi (about 1 per week) so I ordered a Phillips Hue motion sensor to replace it. Should be able to install it tomorrow.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.







