java.lang.NullPointerException in Motion and Mode Lighting Apps

(C-5, 2.2.4.148)

I always get this error when its trggered. java.lang.NullPointerException: Cannot invoke method toInteger() on null object on line 1314 (turnOff)

I don't use motion lighting myself, so am only guessing...

What does the 4 minute delay relate to? Is the idea the lights that you've chosen to turn on are mean to turn off in that time? Or is the idea you are meant to have chosen lights in that "Options for Additional ...." section?

It's the first time I'm using this app and basically if motion is detected turn the lights for 4 minutes then switch off

Are you using mesh linked device in it?

Nope, only got one hub at the moment

Can you screen shot your devices used in the app, include the current States.

Devices are a Hue motion and 4 Ikea bulbs.

Are the lamps on a hue bridge? Or directly connected?

All direct

Can't see any problems with your setup. The only difference between you and me is I tick the box at the top for "per mode settings".

@bravenel is there any known issues?

I have the similar errors but I have been told it's connected to hub connect possible due to earlier beta versions. I have to go through and delete and recreate them, but looks like that's not @djashones issue.

I could do it via RM but this app is much easier :joy:

You should remove this instance of Motion Lighting, and set it up again. It looks as though you had it set up for Scenes, and then changed it perhaps.

I had to do that as I tried per mode settings and it screwed it up totally. So now even more basic i.e. turn the lights when motion detected and turn them off after 4 mins and still the error messages.

Please post the ML setup page, and its App Status page in its entirety (gear icon).

Turn on logging in that Motion Lighting rule. Then post the logs.

Is the issue turning off scene? (which I don't have any) Also why is garage light 3 set to 10, then 100? Tried it a few times and it's the same in the logs. Thanks!

Completely deleted the app and set it up again using a different name and using one light only.

So where is the scene coming from? That's what's throwing the error. Did you by chance delete all of your modes? What mode is your hub in? Show screenshot of your Modes page under Settings.

No modes or scenes. I may of tried modes in the past but I have no need for scenes.