Mode Manager - Mode not switching (Possible bug?)

Hi,

I noticed some odd behaviour in Mode Manager and I am wondering if it is a bug. In a nutshell, it seems that if I mark a mode with "Skip", then the mode thereafter will not engage on time.

In my case, I have night, which I enable via a button, but have scheduled morning to turn on via timer, which will not work.

If I enable Night again, then the modes will switch according to the timer.

What are your thoughts on this, am I doing something wrong?

If you haven’t already, please turn on logging:

Then after having gone through a cycle, filter the logs for the Mode Manager app by clicking on the “Mode Manager” app name under Logs -> Past Logs (or clicking on the app number in the lot itself). Once filtered, you can take a screenshot of the logs and post it here for us to see if we can help determine the issue.

Right, that is the intent of the Skip feature in the Set Mode at Times table. If you want other modes to be set based on time configuration from this table while a particular mode is active (normally the case with most modes), then you should not check the Skip box for that mode. Is there a reason you have this option selected? (It's very common for Away mode because most people want that to be tied to presence and not be affected by time, even if another mode would have normally become active at that time. That best illustrates the use of this feature.)

My understanding was that skip would skip the mode in question, but then the next mode would run based on time.

My reason. For skipping night, based on time, is that I also turn off some lights etc. And being on holiday now I tend to stay up longer. I.e. I don't want it automated, but rather just hit a button before sleep.

If you don't want to set a mode at a specific time, just don't include it in that table. (You can use the "-" button to remove a mode you've already added.)

The "Skip" option is different and behaves as I described above, which you can also read more about in the docs or the "Help for times table" link by the table in the Mode Manager app itself.

1 Like

Well, that would be an easy option for sure :slight_smile:
The interesting thing about this is that it does switch into the other modes based on time.

The morning entry on the 15th was me testing having night set to not skip.

The theory is that the mode right after a skipped one is ignored.

But as you say, I could easily remove night from the app and then things should be OK... Hopefully.

I tried removing the mode, but it doesn't remove it from the list. It does remove it from the list so that I can't remove it again. Effectively I now have something akin to a ghost mode,

You need to use the "-" button to remove it from the table, as I mentioned above. It's also a good practice to remove any references to a certain mode in any app that uses that mode in case that app refers to the mode by its internal ID instead of only its name (which I understand Mode Manager, for the most part, does). It's possible some apps could handle this more gracefully, and it can be tricky because unlike devices, there is no way to tell at a glance what app is "using" a mode. But still, it's a good idea.

At this point, I'd say your options are to restore a hub backup from before this change or (probably eaiser) just remove and re-create Mode Manager.

I think, in addition to Bert's guidance. . . rather, before restoring from a backup, try a graceful shutdown, and unplug the hub for about 20 minutes.

Details fail me now, but I believe that was the last thing I tried when trying to rid myself of a NULL mode I managed to create. I mean, the last thing tried before it was successful.

...bob

Just a note that while it can't hurt, that is unlikely to have any effect on the internal app state of any app (where settings are stored), including this one. IMHO, it's more likely to just waste time--but again, otherwise harmless. :slight_smile:

1 Like

Thanks for the debunk. I post things I THINK I know so it either contributes or it gets publicly corrected. Either way. . .

And, I don't want to be yet another source of disinformation. :innocent:

...bob

Thanks, I did indeed use the "-" button to remove it from the list. That only accomplished removing it from the list of modes that can be removed. This means it is still in the visual list.

I might try removing Mode Manager and set it up again.

The list of modes you can add to the table? That is normal, and you would indeed need to remove it as you did. But it shouldn't cause problems if it's removed from your settings by that point.

Mode Manager is just an app that can help you automate mode changes, one of many options you can use but perhaps the easiest. Nothing you do in Mode Manager can delete or create modes (nor does it hurt to have modes you aren't really "using"). That is done in Settings.

Thank you for thinking along. I do appreciate it, but I also think that we are not fully understanding each other, so I recorded a video of me deleting some modes and as you can see, it seems that once you have changed a mode to not use a timer it does not delete.

Video is here: Mode Manager - YouTube

This is the reason I think there is a bug in Mode Manager.

I then removed it and added again and it comes up automatically with my Away mode, which I am then unable to delete.

I guess I will just populate it now with the modes I want and see how it will work for me.

I don't see any evidence that Mode Manager is still following your schedule, even though it was deleted. I do see the UI retaining the settings if re-added, but that is a (possibly) different issue. It's also a problem I'm not able to replicate, and I suspect you won't, either. If you do, log output would be the best evidence.

Note that you do need to hit Done (or Update -- same thing; it just doesn't close the app page) after you make changes to times (scheduled jobs) or devices (event subscriptions). I don't see that happening in the video, but in the real world, you'll want to do this after making those kind of changes. Think of it as a "Save" button.

This I can replicate -- sort of. It seems there's a problem where if "Away" has "Skip" checked, then it looks like it lets you delete it from the table but doesn't really (it's still there and also missing from the dropdown on the "-" button that lets you remove modes). If "Skip" is not checked, it can be removed properly.

In my quick testing, it also appears to prevent time-based changes to other modes as long as it remains in the table, with or without "Skip" checked, though I didn't exactly test that extensively and suspect it's a bug that it remains there at all. Tagging @bravenel for that one.

Indeed, you wouldn´t see that. The case was that if Night mode was skipped, morning wouldn´t run at set time. If night was set to not being skipped, morning ran fine. Since I have now redone the mode manager and removed night, this isn´t an issue anymore.

I did indeed not show me hitting the Done button as the video was to show the UI inconsistencies.

But thanks for looking into it. Let's see if Bravenel will find anything going on here. Else I have worked around my problem for the time being.