Disconnecting external display confuses macOS when switching users
I have 2 active user accounts on my mac, work and personal, that I switch between multiple times a day. I use it docked, lid open, with an external display most of the time.
If I've logged into and used both user accounts with the external display connected, if I then disconnect the external display, macOS will adjust it's display settings without issue in the currently logged in account. But if I then switch to the other account with the external display still disconnected, macOS appears to "remember" the (larger) resolution of the external display, and the desktop extends beyond the edges of the built-in display, hiding the menu bar and dock. I'll be able to move the mouse around but I won't be able to do anything useful. The only ways I've found out of this limbo state are:
- Reconnect the external display - triggers re-detecting displays and configures both displays properly, after which I can disconnect the external display and it behaves properly
- Logging out or force-powering off
This happens every single time without fail. It's been a persistent issue for years, at least since macOS 12, I believe ever since I moved to Apple Silicon, on both my work-issued 14" M1 Max MacBook Pro and personal 13" M1 MacBook Air, with every display I've ever connected to them, and I'm not the only one to consistently have this issue.
I'm currently still running mos13 on the MBP where it's still an issue; the MBA has been upgraded to mos14 but I can't remember if I've tested the issue and it's away from me while traveling.
MacBook Air 13″