Sunrise / Sunset Bug in 2.2.3.145

So far, the rules that don't work consistently, work when logging is turned on. Something about forcing them to make a log entry is causing them to work correctly.

I found another issue with another rule, that is selectively firing for some devices and not for others.

I have a rule that turns off everything on our upper floor in the morning. Started noticing that some fans are not turning off (all controlled by GE Smart Fan switches). Here are my settings:

Rule

Rule has been firing consistently

But this device no longer getting controlled since 09/11

Here is the settings for the Group that this Switch is part of and is controlled by the rule

Here is another example of another fan that stopped getting events in Aug.

But then here is one of Lutron lights, which is part of the same rule & group, and works just fine. For example the rule turned this light off at 8am, as intended.

So I wonder if one of the firmware updates, broke something with these GE Switches in this case?

I think I am seeing the same time. As I go thru settings of these devices & test then, I am also manually triggering these. And that seem to jump start them and again start getting triggered by rule(s). I have to test more to confirm that it is a confirm behavior though.

Another issue that I discovered is that none of my fan controls are working via rules. I can still control them directly from their respective device page but they don't get triggered via rules anymore. Looks like switch status polling is also not work (for example, if I turn the switch on manually, the device in habitat is not seeing its state change). These are GE Smart Fan controls. Very frustrating, it all used to work until sometime ago.

@gopher.ny did you get a chance to look into these issues? TIA

I think this may be related to hub's time jumps. If at some point the hub thinks it is 2036, it will schedule the next rule trigger into 2036. A save causes it to recalculate next trigger time using current (correct) time.
Now that there's a clear problem definition, I just need to come up with a solution...

1 Like

Related thread:

Never put your hub in the DeLorean.

9 Likes

@gopher.ny Don't want to continue to pester but any update? I continue to see issues - old & new. Is hub gone bad (I only have had it for 4 months). I just created a new rule (motion rule) and it continues to fail every now & then on & off. Sometimes the rule works and sometime it doesn't. Here is the new rule that I created:

Here are the rule logs:

Device (LED Strip) Logs:

Motion Sensor Logs

These logs aren't really useful. What you label as "rule logs" are device logs.

Please turn on logging in the Motion Lighting app, and show those logs when it fails.

So tonight I noticed things all over the place not working. When I went into one of the rules, even though I have all logging turned on, no events showed up in the log and in fact, no new events have been added to the device log for months.

When I Look at the main logs, I see a lot of these:
dev:892020-09-23 11:34:00.494 pm errorjava.lang.RuntimeException: java.sql.SQLException: Connections could not be acquired from the underlying database! (parse)

app:3332020-09-23 11:34:00.478 pm errorjava.lang.RuntimeException: java.sql.SQLException: Connections could not be acquired from the underlying database! (motionHandler)

app:6832020-09-23 10:59:00.511 pm errorjava.lang.RuntimeException: java.sql.SQLException: Connections could not be acquired from the underlying database! on line 7069 (allHandlerT)

dev:892020-09-23 10:40:37.753 pm errorjava.lang.RuntimeException: java.sql.SQLException: Connections could not be acquired from the underlying database! (heartbeat)

dev:762020-09-23 10:40:37.704 pm errorjava.lang.RuntimeException: java.sql.SQLException: Connections could not be acquired from the underlying database! (parse)

Here are some screen shots for context...

This looks ripe for a hub reboot. If that does not cure the issue, next step is soft reset. Here's a "best practice" approach to it:

  • Take a backup, and download it locally (just in case).
  • Perform a soft reset in the Diagnostics Tool. DO NOT DO A FULL RESET - that will clear radios.
  • Restore from the latest backup (one you've just taken). If you don't see backups listed immediately after soft reset (we saw it happened a few times), reboot the hub, and it will pick them up.

Time jumps will be addressed in 2.2.4 firmware update. There's no built in battery, but huge jumps into either future or past will be detected. Hub time might still be off until proper time sync, but not by years.

The logging is already enabled. Here is the output:

The event at ~9:33 failed to turn the LED on whereas the motion was triggered at 9:32:13. The device logs says that LED was already on, but it was not.

Then the same rule worked just fine at 9:54

If you look at the second log, where you have the red arrow, just above that (later) it explains that it is not turning on the light because it thinks the light is already on.

You can override this with the option under Options for On called 'Do turn on if already on':

Thanks for the assist. I turned that config 'on' and will monitor. But isn't it still is issue that it thinks that light is on when it is not really 'on'?

Here is a simple one that I caught that is not triggering. The logging was turned off on it. I just turned logging on, and I bet that will "fix" the issue.

Just look at the App Status page and see if there is a Schedule Job at the bottom, for 7:30 AM tomorrow. App Status page is gotten to by the gear icon upper right in the app, or to the left of the app in the Apps list.

Oh, and turning on logging won't make it work, but throwing salt over your left shoulder should do the trick.

Keeping the joy going, here is yet another of my Mode apps, that is not working:

Nothing in the App Events

Here is the App status page

Last time the LED 1 & LED 2 turned on were >8 days ago, also looks like something went bonkers on 20th for LED 1 & 18th for LED2 respectively, there are dozens of events on those respective days

You are misunderstanding the purpose of this app. It doesn't turn things on or off with mode changes. Its purpose is for switch activated lighting to be set to an appropriate level per mode when the switch is activated. You don't even have an activation switch selected. But, that's irrelevant -- you need a different app. Take a look at Simple Automation Rules.

Haha, Thanks. So far the automations that did not work started working again as soon as logging was enabled.

Here is the screen shot for scheduled job: