Bug 511918

Summary: Switching to an already logged-in user causes Plasma to display a black screen with no cursor
Product: [Plasma] plasmashell Reporter: zupnikszydlik
Component: Session ManagementAssignee: Plasma Bugs List <plasma-bugs-null>
Status: REPORTED ---    
Severity: normal CC: kdedev, natalie_clarius, nate
Priority: NOR    
Version First Reported In: 6.5.2   
Target Milestone: 1.0   
Platform: Manjaro   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: journalctl log 1
journalctl log 2
gdb log

Description zupnikszydlik 2025-11-10 15:29:32 UTC
SUMMARY
When attempting to switch users via the "Switch User" option and selecting an account that is already logged in (either the same or a different one), Plasma becomes unresponsive and displays a black screen.

STEPS TO REPRODUCE:
1. Log into a user account.
2. Select the "Switch User" option.
3. Choose the same account or another account that is already logged in.

OBSERVED RESULT
Plasma freezes and becomes unresponsive, showing only a black screen.

EXPECTED RESULT
Successful login into the selected account without freezing or display issues

SOFTWARE/OS VERSIONS
Operating System: Manjaro Linux 
KDE Plasma Version: 6.5.2
KDE Frameworks Version: 6.19.0
Qt Version: 6.10.0
Kernel Version: 6.12.57-1-MANJARO (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 3600 6-Core Processor
Memory: 16 GB of RAM (15.5 GB usable)
Graphics Processor: NVIDIA GeForce GTX 1070
Comment 1 TraceyC 2025-11-13 20:35:23 UTC
Thanks for the bug report. When this happens, are you able to get to a TTY with Ctrl+Alt+F3?

If so, can you check kwin's logs:

  journalctl --boot --user-unit plasma-kwin_wayland > ~/log.txt

Also, could you retrieve kwin's backtrace while the bug is happening? You might need to ssh from another computer and attach a debugger to kwin process if it's hung, e.g.

  sudo gdb -p $(pidof kwin_wayland)

then type

  bt

then press 'c' if it asks you if you want to continue paging

Then copy-and-paste the output here. Thanks!
Comment 2 zupnikszydlik 2025-11-14 14:10:53 UTC
Created attachment 186782 [details]
journalctl log 1
Comment 3 zupnikszydlik 2025-11-14 14:11:16 UTC
Created attachment 186783 [details]
journalctl log 2
Comment 4 zupnikszydlik 2025-11-14 14:14:33 UTC
Created attachment 186784 [details]
gdb log

trying to get information using gdb
Comment 5 zupnikszydlik 2025-11-14 14:16:44 UTC
I created the logs you asked about: first with my daily account, and second with the breeze-only theme.

Regarding gdb: I tried, but I’m not very familiar with debugging, sorry. I used a second computer with SSH. Every time I tried to debug, nothing really happened. I logged into the account, ran gdb, and always got the same output (which I don’t think is very useful).

In the gdb session I used "bt", then repeated "bt" after 30 seconds. Afterwards I used "c" (as I read in the manual it continues the program), but mostly nothing happened. In the attached log I got information about 4 threads, but most of the time after entering "c" there was no reaction. After about one minute without any response I quit gdb.
Comment 6 zupnikszydlik 2025-11-14 14:18:13 UTC
What is interesting is that I was able to return to the login screen by switching between ttys (e.g. tty3, tty2, and tty1 — the one with the login screen).

Through SSH I checked what happens after clicking the "Switch user" option and logging into the same account: the screen stayed black, but I could see two login processes. After entering the password there were two ""/usr/bin/startplasma-wayland processes"", one on tty1 and another on tty4.

Logging in → Select "Switch user" → Go back to login screen
[radek@radek-komp ~]$ w
 14:42:16 up 27 min,  5 users,  load average: 0,16, 0,14, 0,13
UŻYTK.  TTY       ZAL.OD   BEZCZ. JCPU   PCPU  CO
radek    tty1      14:15   27:21   0.03s  0.03s /usr/bin/startplasma-wayland
radek    pts/2     14:19    0.00s  0.01s  0.01s w

Selecting to log into the same account:
[radek@radek-komp ~]$ w
 14:42:27 up 27 min,  6 users,  load average: 0,12, 0,14, 0,13
UŻYTK.  TTY       ZAL.OD   BEZCZ. JCPU   PCPU  CO
radek    tty4      14:42   27:32   0.04s  0.04s /usr/bin/startplasma-wayland
radek    tty1      14:15   27:32   0.03s  0.03s /usr/bin/startplasma-wayland
radek    pts/2     14:19    0.00s  0.01s  0.01s w

It stayed like this (black screen, no login option):
[radek@radek-komp ~]$ w
 14:42:44 up 27 min,  6 users,  load average: 0,10, 0,13, 0,13
UŻYTK.  TTY       ZAL.OD   BEZCZ. JCPU   PCPU  CO
radek    tty4      14:42   27:49   0.04s  0.04s /usr/bin/startplasma-wayland
radek    tty1      14:15   27:49   0.03s  0.03s /usr/bin/startplasma-wayland
radek    pts/2     14:19    0.00s  0.01s  0.01s w

After switching between ttys and returning, USER's login screen showed up and I had to enter my password again (that one that shows up after Meta+L):
[radek@radek-komp ~]$ w
 14:42:56 up 28 min,  6 users,  load average: 0,08, 0,12, 0,12
UŻYTK.  TTY       ZAL.OD   BEZCZ. JCPU   PCPU  CO
radek    tty1      14:15   28:01   0.03s  0.03s /usr/bin/startplasma-wayland
radek    pts/2     14:19    0.00s  0.01s  0.01s w
Comment 7 TraceyC 2025-11-14 21:14:46 UTC
Thanks for the additional details, that's really helpful. I'll let those more knowledgeable about this code look further.
Comment 8 Nate Graham 2025-12-12 21:22:09 UTC
Can you paste the output of `cat /etc/sddm.conf`?