Doesn't restore laptop display when switching TTYs+undocking

I have two accounts on my machine (both using sway) and I switch between them using control+alt+f{1,2}. Kanshi remembers the state of the TTY when I switch but doesn't detect any changes when I switch back. My kanshi config is:

    output "Unknown 0x109D 0x00000000" enable  # Laptop

    output "Unknown 0x109D 0x00000000" disable  # Laptop
    output "ViewSonic Corporation VP2768 Series UY5182100007" enable  # external monitor

To illustrate the issue, here's a scenario:

  • Work in TTY1 undocked
  • dock laptop (external monitor)
  • Switch to TTY2 and work
  • Undock laptop while in TTY2
  • Switch to TTY1 and notice a dead screen

At this point, Kanshi hasn't returned the display back to the laptop. TTY1 is also unresponsive, i.e. I'm unable to blindly type commands to save the situation - something's blocking (perhaps not a Kanshi bug, then?).

The situation then gets more awkward because, while I can rescue the session by docking the laptop and undocking again, Kanshi somehow does detect the dock on TTY2 and then activates the external monitor/disables the laptop display in the background.

github.com:ainola (unverified)
Assigned to
1 year, 11 months ago
2 months ago
No labels applied.

github.com:ainola (unverified) 7 months ago · edit

This seems to have not been an issue for me for some weeks now - I'm guessing this was a kernel issue after all? Can anyone confirm?

~ainola 2 months ago

It seems there was a glorious period where this was 100% reliable, and then as the system updates came through eventually this broke again. So it definitely seems to caused by something else but I'm not sure what. Sadly, it's at the point where it's exhibiting the behavior despite for some time now.

$ glxinfo | grep Device
    Device: Mesa Intel(R) HD Graphics 630 (KBL GT2) (0x591b)
Register here or Log in to comment, or comment via email.