[Released] Rule 4.0

Do you know what you were doing when that happened. Try restoring a backup of your database and see if it still does it. If so, then you should roll back from this release.

I was logging in with the intent to create a new rule, and also to reboot the hub due to some instability issues when I saw the update. After triggering the update, I did not touch it again for about an hour, IIRC.

Does the database back up automatically? I've not touched any of these functions before.

browse to Settings: Backup and Restore.

Click "Create a new backup and download locally"
That will get a current copy of the DB onto your computer, in case it's needed later. If you're not in a rush, go ahead and click Download for at least one older too.

Then click restore of the Oldest (probably the last line showing) and let it complete.

TEST
Is it working right now?

Yes? Wonderful. Get comfortable with taking a backup periodically.

No? OK, same deal, Settings: Backup and Restore and above the list of on-hub backups is a sentence it's easy to overlook:

"If you want to restore a previous Platform Version click here."

"Restore Previous version"

Click there and choose 2.1.3.128 or 2.1.4.119, which ever one you were on before.

56%20PM

Got it -- I tried to restore DB of one today, (after it started having issues,) and also restored one from yesterday, which was on another version.

Still get the same error.

Sounds like maybe I'll need to roll back to the previous OS, then restore a compatible DB.

Thanks for reporting this, and for your patience. What you've told me is what I needed to know. This bug will be fixed shortly.

The latest release should fix this problem. Please give it a try and let us know!

Awesome, I'll update now. Just for the record, when I fully rolled back to 2.1.4.119 yesterday using the :8081 interface, that did resolve my issue. Whats interesting is my rules were still triggering, but I couldn't make any changes to them. My guess is it was only impacting the UI and not the underlying scheduling/logic system.

Any chance of adding "with fade time" to the various "set color/temp and level / per mode" actions?

I must be a malfunction-magnet, haha. Update installed, but my hub powered off completely afterwards. Luckily I was home, otherwise that would have been a bit of a nightmare.

@bravenel

What's wrong with this rule? Been trying to fix it for a while now. The 5 second delay is so that the 4 minute turn off occurs and doesnt send redundant messages.

You are getting multiple simultaneous executions. That's not going to work. They are colliding with each other.

Mike, you might be able to use a private boolean to prevent multiple instances of this rule running. First line could stop the rule if PV false. I assume this would not impact the original rule that might still be running.

Does anyone know how much of the beginning of this rule is redundant? I'm trying to prevent the motion from triggering after someone turns the switch on manually -- at least for a few minutes.

Bruce,

Does private boolean preclude a rule from running in Rule 4, like it did in Rule 3? Or is it simply a like a virtual switch, that I can use in Rule machine to "exit rule" for example. I cant find any documentation as to what it does in the support docs.

Works like a local variable. In rm4 it doesn't do anything to action execution unless you explicitly use it that way.

Restrictions are gone. So only whatever logic you use for it will apply. It's like a simple Boolean variable, that starts out true. You can test it, set it, have other rules set it, and trigger off it. It's all up to you what you do with it. It can often be used instead of a virtual switch to remember some state.

1 Like

So, I know I said I couldn't think of how you'd use an XOR....well, I did. :slight_smile: Took me a while but it finally clicked. Thanks again for taking the time to explain it to me.

Every time I think I've wrapped my head around 4.0, I get surprised by something. I threw together a quick rule to wake me up at 6:43 AM on August 27th, and it got the job done. But it also turned on the light at 6:43 AM on August 28th. Why? I know as soon as someone points out my error, I will say "Doh!".

Your trigger runs at 6:43 everyday.
In your actions you have your dimmers that you set.
Although you have a condition defined you have not actually used it.
Leave your trigger.
In actions use an IF-THEN.

IF
Date is Aug 27th. (The condition you have already defined)
THEN
Turn on dimmers.
END-IF.

Thank you. My head was erroneously thinking RM 3 Restriction and RM 4 Condition were the same, but they are not.

While I've done 30+ rules in RM 4 that are all working as intended, I haven't reached full understanding of the somewhat murky terminology. For example if you want to edit an If/Then construct, the UI to go through says you are editing an action.

I know it is easier said than done, but if would be nice if a future RM separated the notion of creating actions (things to do) and logic constructs (initially empty; into which actions are inserted).