I think I found a bug in the Motion Lighting app

I'm here to report a bug I found in the Motion Lighting app - but in the process I'm noticing there is also a bug from 2019 that's still not fixed? Hopefully this can bring the spotlight back on that as well.

The old: When you go to start a new child app and you select "use settings per mode" the slider goes away, so you have to delete it and start over should you want to ever change that.

The new: When you select "control switches per mode" the option to set what each modes switches are never appears as it does with the other "per mode" menu items. In other words, I want 2 switches to be turned on if it's "daytime" and one if it's "night time" and that ability to select those per mode does not appear, only one menu to select switches and then the modes for those switches. (but only once). Gotta do it by hand in rule machine now!

As for the second bug you mentioned - I am seeing the same thing but I always thought this is the way it was meant. I then just create two rules. One for daylight and the other for night time :man_shrugging:

I don't think so - because for the other items - for example "delay off".. i choose which modes I want to use. Then, I am given an input place for each mode. For example, I can say "delay off for 0 minutes in Away, 5 minutes in Daytime, 1 minute for night". I should be able to do the same for the switches. If that's the way it's supposed to be, I would argue that's not the way it should be to be consistent with the way the other variables work. I'm glad it's not just me that it seeing it this way though!

I always assumed that the "Use per mode setting" was intended to not be un-settable once set, perhaps due to the complexity of setting changes it makes when enabled; all I do know for sure is that it's worked this way for a long time, possibly forever, and creating a new app instance is the only way to get rid of it.

For "switches per mode," that might be the intended behavior, too, though it's a bit different. It doesn't seem inconsistent with the documentation:

Select which switches you would like to turn On when motion is activated and select the modes for which the switches will be active.

...though that particular implementation certainly isn't the only way it could work.

What you might want to do instead in case you haven't considered it is to make a scene, then activate scenes per mode. Of course, creating a rule as it sounds like you might be doing now is another way. :slight_smile:

@bertabcd1234's description is completely correct. Neither feature you've described are bugs.

The removal of the "Use per mode setting" is intentional, and necessary. There are basically two apps in one: one uses per mode settings and the other doesn't.

"switches per mode" works as intended. You select the switches you want turned on in the selected modes. Compare to "dimmers per mode". In that you select the dimmers, and the levels for each mode. For a switch, the only choice is to turn it on.

This all makes sense if you view Motion Lighting in its entirety. If all you want to do is control switches per mode, consider using Rule Machine's 'Set switches per mode' action. This could be triggered by motion, and use Wait For Condition - motion inactive with a duration to turn off.