Pistons ignoring restrictions


#1

I posted about this issue 10 days ago on the ST forums HERE so re-posting on these forums in effort to get this resolved as it’s causing issues with a lot of my pistons and still an outstanding issue

Original post:

I am having issues since the latest update with Pistons executing and ignoring restrictions. I’ve isolated the problem to pistons that have a duration trigger (IE: If lights are off for 5 minutes then…) kind of triggers. It’s currently 14:26 and the restrictions on my piston are for the Piston to only fire between 21:00 and 05:00 but it keeps executing.

At 14:17:48, a scheduled job is setup to run but shouldn’t be due to the time restrictions. Once that time hits, the piston runs and the Goodbye! routine is run

+600ms ║Setting up scheduled job for Wed, Aug 16 2017 @ 2:22:49 PM EDT (in 299.939s)

I’ve had this piston running this way without modification for over a month and this issue just started after upgrading webCoRE the other day to the latest version

Here are the logs and the piston itself:

16/08/2017, 14:22:48 +258ms
+1ms ╔Received event [Homelands].time = 1502907769040 with a delay of -783ms
+560ms ║RunTime Analysis CS > 145ms > PS > 98ms > PE > 317ms > CE
+579ms ║Runtime (39477 bytes) successfully initialized in 98ms (v0.2.0e5.20170812) (577ms)
+582ms ║╔Execution stage started
+614ms ║║Cancelling condition #11’s schedules…
+620ms ║║Condition #11 evaluated true (8ms)
+692ms ║║Comparison (enum) off is (string) off = true (5ms)
+701ms ║║Comparison (enum) off is (string) off = true (6ms)
+710ms ║║Comparison (enum) off is (string) off = true (5ms)
+717ms ║║Comparison (enum) off is (string) off = true (4ms)
+722ms ║║Comparison (enum) off is (string) off = true (3ms)
+728ms ║║Condition #15 evaluated true (106ms)
+730ms ║║Cancelling condition #4’s schedules…
+732ms ║║Condition group #4 evaluated true (state changed) (121ms)
+739ms ║║Cancelling statement #12’s schedules…
+794ms ║║Executed virtual command sendPushNotification (42ms)
+10236ms ║║Executed virtual command executeRoutine (9433ms)
+10241ms ║╚Execution stage complete. (9659ms)
+10250ms ╚Event processed successfully (10250ms)

16/08/2017, 14:17:48 +502ms
+1ms ╔Received event [Theatre Mood Light].switch = off with a delay of 259ms
+403ms ║RunTime Analysis CS > 88ms > PS > 78ms > PE > 237ms > CE
+413ms ║Runtime (39476 bytes) successfully initialized in 78ms (v0.2.0e5.20170812) (410ms)
+414ms ║╔Execution stage started
+431ms ║║Comparison (string) :e329209b02524180269aeacb19563898: is_any_of (string) :beaf06d1244cff657bfc5a964ce25c62:,:e329209b02524180269aeacb19563898: = true (4ms)
+433ms ║║Condition #1 evaluated true (11ms)
+450ms ║║Comparison (time) 51468937 is_between (time) 75600000 … (time) 18060000 = false (10ms)
+452ms ║║Condition #2 evaluated false (18ms)
+454ms ║║Condition group #null evaluated false (state did not change) (33ms)
+455ms ║║Piston execution aborted due to restrictions in effect
+473ms ║║Comparison (time) 51468962 is_between (time) 75600000 … (time) 18000000 = false (10ms)
+516ms ║║Comparison (enum) off stays (string) off = true (4ms)
+520ms ║║Comparison (enum) off stays (string) off = true (3ms)
+525ms ║║Comparison (enum) off stays (string) off = true (3ms)
+529ms ║║Comparison (enum) off stays (string) off = true (2ms)
+533ms ║║Comparison (enum) off stays (string) off = true (3ms)
+538ms ║║Adding a timed trigger schedule for condition 11
+570ms ║║Comparison (enum) off is (string) off = true (3ms)
+573ms ║║Comparison (enum) off is (string) off = true (2ms)
+577ms ║║Comparison (enum) off is (string) off = true (3ms)
+581ms ║║Comparison (enum) off is (string) off = true (3ms)
+585ms ║║Comparison (enum) off is (string) off = true (2ms)
+588ms ║║Cancelling condition #15’s schedules…
+597ms ║╚Execution stage complete. (184ms)
+600ms ║Setting up scheduled job for Wed, Aug 16 2017 @ 2:22:49 PM EDT (in 299.939s)
+619ms ╚Event processed successfully (620ms)

16/08/2017, 14:17:41 +176ms
+2ms ╔Received event [Theatre Mood Light].switch = on with a delay of 188ms
+699ms ║RunTime Analysis CS > 140ms > PS > 323ms > PE > 236ms > CE
+709ms ║Runtime (39477 bytes) successfully initialized in 323ms (v0.2.0e5.20170812) (706ms)
+710ms ║╔Execution stage started
+728ms ║║Comparison (string) :e329209b02524180269aeacb19563898: is_any_of (string) :beaf06d1244cff657bfc5a964ce25c62:,:e329209b02524180269aeacb19563898: = true (5ms)
+731ms ║║Cancelling condition #1’s schedules…
+732ms ║║Condition #1 evaluated true (12ms)
+748ms ║║Comparison (time) 51461909 is_between (time) 75600000 … (time) 18060000 = false (10ms)
+751ms ║║Condition #2 evaluated false (17ms)
+752ms ║║Condition group #null evaluated false (state did not change) (34ms)
+753ms ║║Piston execution aborted due to restrictions in effect
+772ms ║║Comparison (time) 51461934 is_between (time) 75600000 … (time) 18000000 = false (10ms)
+775ms ║║Cancelling condition #4’s schedules…
+822ms ║║Comparison (enum) off stays (string) off = true (3ms)
+826ms ║║Comparison (enum) off stays (string) off = true (3ms)
+831ms ║║Comparison (enum) off stays (string) off = true (2ms)
+835ms ║║Comparison (enum) on stays (string) off = false (2ms)
+839ms ║║Comparison (enum) off stays (string) off = true (3ms)
+844ms ║║Cancelling any timed trigger schedules for condition 11
+845ms ║║Cancelling statement #11’s schedules…
+846ms ║║Cancelling condition #11’s schedules…
+881ms ║║Comparison (enum) off is (string) off = true (3ms)
+885ms ║║Comparison (enum) off is (string) off = true (3ms)
+889ms ║║Comparison (enum) off is (string) off = true (3ms)
+893ms ║║Comparison (enum) on is (string) off = false (3ms)
+897ms ║║Cancelling condition #15’s schedules…
+906ms ║╚Execution stage complete. (196ms)
+914ms ╚Event processed successfully (914ms)


#3

I think the problem is with the timed triggers (stays) - and they’d don’t really do anything, but they should no longer cancel tasks? There is an option in the piston to allow or disabled pre-scheduled tasks running at restricted times I think?


#4

same issue here – been happening for a week or so? one update seemed to trigger it.

not sure where to find that option mentioned…


#5

I am not sure I understand this answer especially “- and they’d don’t really do anything, but they should no longer cancel tasks”. As previously stated, my pistons were running with this configuration/setup for months before the last 2-3 commits broke them. I now place the restrictions on the “Then” part of the piston to stop it running. My example above shows that there is a scheduled job setup to run for 5 minutes which is causing the execution. Why is there are scheduled job created when the restriction implicitly states no action should be taken unless between 9PM and 5AM? This is not an issue with the piston creation, something is ignoring the restrictions in place and causing the piston to run.

Like @sphen I am unable to locate the option you thought maybe available. Please let me know what else I can provide to fix this bug. Thanks