Linux version 5.15.133.1-microsoft-standard-WSL2 (root@1c602f52c2e4) (gcc (GCC) 11.2.0, GNU ld (GNU Binutils) 2.37) microsoft/WSL#1 SMP Thu Oct 5 21:02:42 UTC 2023
Distro Version
Ubuntu 22.04
Other Software
xclock installed by whatever the shell suggests when you type 'xclock' at it ("sudo apt-get install x-"something, I think)
Also, emacs, also installed with apt-get.
Repro Steps
I am using the (mostly wonderful) built-in X server in Windows+WSL. After 15 minutes or so my computer locks automatically, and often I use Windows-L to lock the computer.
To a command prompt, Linux shell, type "xclock &", "emacs &".
Lock the screen.
Unlock the screen.
I've seen three behaviors:
When I unlock the screen, it looks like xclock has reported "X connection to :0 broken (explicit kill or server shutdown)." to the controlling terminal, and xclock has exited with status 1. Emacs is less forgiving --- it aborts and coredumps.
The second behavior is similar: only, now when I start a new xclock to replace the original, there's no window decorations:
The above two behaviors don't always happen. Often, my X windows have just disappeared. I can get them back by poking the X server with an X application (e.g., another invocation of xclock). Then all the X-gui-using programs come up on the screen (at least one of their windows, at least).
Expected Behavior
I'd like my X programs to survive a locked screen.
When they survive the locked screen, I'd like them to refresh and reappear automatically, just as though they'd gotten an expose-event or something similar.
Actual Behavior
See above. Locking the screen appears to shut down the X server, and sometimes leaves its internal window-manager confused.
I've seen this repetitively with my intellij environments, but it doesn't always require a lock screen, I've seen it happen when the Windows desktop background changes as well.
Windows Version
Microsoft Windows [Version 10.0.22621.2715]
WSL Version
2.0.9.0
Are you using WSL 1 or WSL 2?
Kernel Version
Linux version 5.15.133.1-microsoft-standard-WSL2 (root@1c602f52c2e4) (gcc (GCC) 11.2.0, GNU ld (GNU Binutils) 2.37) microsoft/WSL#1 SMP Thu Oct 5 21:02:42 UTC 2023
Distro Version
Ubuntu 22.04
Other Software
xclock installed by whatever the shell suggests when you type 'xclock' at it ("sudo apt-get install x-"something, I think) Also, emacs, also installed with apt-get.
Repro Steps
I am using the (mostly wonderful) built-in X server in Windows+WSL. After 15 minutes or so my computer locks automatically, and often I use Windows-L to lock the computer.
To a command prompt, Linux shell, type "xclock &", "emacs &".
Lock the screen.
Unlock the screen.
I've seen three behaviors:
Expected Behavior
I'd like my X programs to survive a locked screen.
When they survive the locked screen, I'd like them to refresh and reappear automatically, just as though they'd gotten an expose-event or something similar.
Actual Behavior
See above. Locking the screen appears to shut down the X server, and sometimes leaves its internal window-manager confused.
Diagnostic Logs
No response