RM Set Variable Question

Question... When you are doing multiple math steps on a variable in an RM rule via Set Variable, have others seen a need to put delays between the math steps to ensure the variable gets updated before RM goes to the next action?

It has been working OK for me in testing but I don't do a lot of RM, or new hub variables, so thought I would ask people's experience.

Example below. Will RM do the actions so fast that "PoolRuntime" doesn't get updated before the next action runs?

EDIT: Since someone asked... The last set variable action is to put the DECIMAL variable into a NUMBER variable otherwise the RM rule will crash when you try to assign the decimal variable to a delay on a switch control action.

Probably as expected @bravenel , but I thought I would mention it. To say it more clearly, assigning DECIMAL hub variables to a switch off action delay makes the rule error out a la:

Example of variable math actions in a row:
image

No. There is no "updating" step that has to be waited for (if you discover something do let us know, as that would be a surprise). These should be very fast.

With respect to decimal variable delay, evidently there is a bug in Rule 5.0 with this, and I will get it fixed for next release.

Update: found and fixed the decimal variable delay bug. It has millisecond resolution, although as a practical matter there's slop around those types of timings.

2 Likes

Awesome! You are a machine when it comes to fixing identified issues.

I assumed you would just do something like a floor/ceiling on it, and call it a day. Wasn't expecting support for fractional seconds lol.

All of my delays are in hundreds and thousands of seconds, so some slop won't bother me any. :slight_smile:

Fractional seconds have been supported since at least Rule-4.0. It's just that decimal variable broke somehow in Rule 5.0. (or maybe it didn't work and no one noticed).

1 Like