Rm 5.1

I was editing a rule and after trying to copy and paste stated receiving this error
and now cannot do any further editing

An unexpected error has occurred trying to load the app. Check Logs for more information.

Error: Cannot invoke method getDisplayName() on null object

here is a screenshot of actions...

receive this error when I click to edit

and this is what shows in the logs

java.lang.NullPointerException: Cannot invoke method getDisplayName() on null object on line 4439 (method selectActions)

any help would be appreciated.
Thanks

Restore a backup from before you began editing.

1 Like

If you Export this rule and send it to me, I should be able to help you. Please see PM I just sent you.

1 Like

On another topic, you don't want to put a minute delay between your IF-THEN and your ELSE-IF statements.

Time between 12:00 AM and 8:30 AM is true between 12:00:00.000 and 8:29:59.999
Time between 8:31 AM and 7:00 PM is true between 8:31:00.000 and 6:59:59.000
Any time between 8:30:00.000 to 8:30:59.999 will satisfy the ELSE statement.

Additionally, I'm not sure how the first nested IF-THEN can even be true. If the time is between 9:00 AM and 9:00 PM then it can't also be between 12:00 AM and 8:30 AM. Maybe that was the point of editing this rule, not sure. If not, you may want to take a look at your logic again and perhaps change or simplify this rule.

1 Like

yeah.. the snapshot is as it is right now, it broke in the middle while I was moving the conditional statements to the appropriate places...

I ended up recreating the rule because the old rule would not even export !
this is what I was trying to get to when the error started showing up.

where is the delay ? There was another thread a while ago that 8:30 (in the end time) is actually 8:30:59 and not 8:30:00 while 8:30 (in start time) is 8:30:00

anyways.. will close this out as I have redone the rule from scratch and removed the old one

If Time IS 8:30 AM then that is true between 8:30:00.000 and 8:30:59.999. That is not the same as Time BETWEEN 12:00 AM and 8:30 AM. Since you're using between bump them right up next to each other, otherwise you have a minute dead spot in your rule.


Time of day: "Time is 8:30 AM" will be True from 8:30:00 until 8:30:59.999
Between two times: "Time between 12:00 AM and 8:30 AM" will be True from 12:00:00.000 until 8:29:59.999

3 Likes

I just had the same issue with a rule. I was editing it and something went wrong and now I can't edit, clone or export it. I assume it is still running. @bravenel assuming I can't export it then I imagine there is not much you can do? Thanks.

Not sure what the "same issue" is. But if you can't edit the rule, you will need to remove it and recreate it. Without knowing the exact sequence of steps to recreate the problem, there isn't anything I can do.

I did end up recreating the rule but kept the old one disabled just in case. The steps I went through:

Existing rule - been using for a while
Went in and inserted a Wait on expression successfully.
Then attempted to copy this expression to another part of the rule.
Copied it fine
Went to insert it and got the same error as OP - Error: Cannot invoke method getDisplayName() on null object
Now I get this error each time I try to edit the actions on the rule and can't clone or export it.
Not sure if that provides any more help - but will delete the rule soon if there is nothing more to be gained.

Do you mean you tried to copy the Wait for Expression action?

That’s correct. Copied fine. Paste failed.

Can you tell me what the expression was? I'd like to try to reproduce this.

Yes, it was:

Wait for Expression: mZone-Kitchen motion inactive

And mZone-Kitchen is a Zone Motion Controller with several motions sensors in it. I didn't try to do it again. I just recreated the rule and created the lines manually.

I am not able to reproduce this problem. If you would be so kind to check this again after the next release comes out (2.3.6), that would be helpful.

ok. Thanks.

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