Rule Machine: Error after using undefined variable for delay

Today I was adding a delay to a rule using a variable for the seconds field. I typed the name of the variable wrong, and before I clicked Done the rule errored out with a java.lang.NullPointerException: Cannot get property 'val' on null object on line 655 (selectActions) and now I cannot edit the rule at all.

I'm running version 2.2.0.132.

Steps to recreate issue:

  • Create new rule
  • Add delay
  • Set seconds field to '%asdf'
  • Click outside of the seconds field

Let me know if any further information is needed

That's touchy. Better not get a drink of water while making that rule :laughing: Did you happen to click out of the input field? (seems apps likes to save, or update when I do that)

Since you stated Rule Machine in the subject I'm tagging @bravenel to chime in on this one.

Unfortunately at this point you might need to delete the rule and start again (typing variables carefully :wink: ), but let Bruce confirm that before doing so.

Once a rule is broken by certain missteps, it's broken and has to be removed and recreated. %asdf is not a well formed variable reference, and clicking outside the string input caused the break.

This particular break is easy to fix, and the fix will be in the next release. This was only introduced recently. Thanks for bringing it to my attention @TechMedX .

1 Like

So in the next release, entering '%asdf' and selecting outside of the string input will not break the rule?

Correct. What it will do is to give you a "bad value" in that field, which can then be edited to correct it, instead of throwing an error.

2 Likes

Perfect. Thanks for fixing it!

It appeared global connectors stopped functioning with the new build.

When I attempt to add a new conditional to an existing rule, RM now freezes. Attempts to re-open the rule result:

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.