Bug 467074 - On X11, when returning from screen energy saving, Plasma forgets that an external screen is connected and doesn't assign it a containment
Summary: On X11, when returning from screen energy saving, Plasma forgets that an exte...
Status: RESOLVED WORKSFORME
Alias: None
Product: plasmashell
Classification: Plasma
Component: Desktop Containment (show other bugs)
Version: 5.27.2
Platform: Other Linux
: HI normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords: multiscreen
: 470184 470799 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-03-08 20:08 UTC by Linus Kardell
Modified: 2024-03-15 03:46 UTC (History)
13 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
plasmashell journal output (72.85 KB, text/x-log)
2023-03-09 18:01 UTC, Linus Kardell
Details
Screen management screenshot (2.44 MB, image/png)
2023-04-03 17:56 UTC, Linus Kardell
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Linus Kardell 2023-03-08 20:08:08 UTC
SUMMARY
Frequently when coming back to my computer after leaving it for a while, plasmashell will be blacked out and unresponsive. I think this started with the update to 5.27.2 from 5.27.0.

STEPS TO REPRODUCE
1. Lock the computer and leave it alone for a while
2. Come back to it

OBSERVED RESULT
Sometimes, the desktop background is black, and the panel does not show up when moving cursor to bottom of screen (I have autohiding panel)

EXPECTED RESULT
Plasmashell works as normal

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20230306
KDE Plasma Version: 5.27.2
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Kernel Version: 6.2.1-1-default (64-bit)
Graphics Platform: X11
Processors: 16 × AMD Ryzen 7 5800X 8-Core Processor
Memory: 62.7 Gibyte of RAM
Graphics Processor: NVIDIA GeForce RTX 2080 Ti/PCIe/SSE2
Manufacturer: ASUS
Comment 1 Linus Kardell 2023-03-09 18:01:02 UTC
Created attachment 157155 [details]
plasmashell journal output

Output from plasmashell in the journal. The final lines from 18:55:50 is about the time I unlocked the session.
Comment 2 Nate Graham 2023-03-13 19:26:09 UTC
Sounds like Plasma might be crashing. If you run `coredumpctl --reverse` in a terminal window, do you see any plasmashell crashes in the list?
Comment 3 Linus Kardell 2023-03-14 18:53:38 UTC
Functionally it might as well be crashed. However there is no core dump, and the process is still running  (which also means systemd doesn't restart it).
Comment 4 Nate Graham 2023-03-15 15:28:36 UTC
All right, so it really is a hang and not a crash. Can you get a backtrace of what plasmashell is doing when it's hung?

1. Run `gdb attach $(pidof plasmashell)` in a terminal window
2. If it says "--Type <RET> for more, q to quit, c to continue without paging--" at the bottom of the terminal window, press the return key. Do this until it stops saying that
3. When you see a prompt that says "(gdb)", type "bt" and press the enter key
4. If it says "--Type <RET> for more, q to quit, c to continue without paging--" at the bottom of the terminal window, press the return key. Do this until it stops saying that
5. Copy-and-paste the contents of the terminal window into a comment here
Comment 5 Linus Kardell 2023-03-16 21:07:35 UTC
In GDB I get:
#0  0x00007ff12b50bc5f in __GI___poll (fds=0x5630ef409ca0, nfds=11, timeout=6) at ../sysdeps/unix/sysv/linux/poll.c:29
#1  0x00007ff12a8bfdbe in g_main_context_poll (priority=<optimized out>, n_fds=11, fds=0x5630ef409ca0, timeout=<optimized out>, context=0x7ff120005010) at ../glib/gmain.c:4553
#2  g_main_context_iterate (context=context@entry=0x7ff120005010, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/gmain.c:4243
#3  0x00007ff12a8bfedc in g_main_context_iteration (context=0x7ff120005010, may_block=1) at ../glib/gmain.c:4313
#4  0x00007ff12bd33c16 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) (this=0x5630e5adf5f0, flags=...) at kernel/qeventdispatcher_glib.cpp:423
#5  0x00007ff12bcdac5b in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=this@entry=0x7fffa1fa47e0, flags=..., flags@entry=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
#6  0x00007ff12bce2dc6 in QCoreApplication::exec() () at ../../include/QtCore/../../src/corelib/global/qflags.h:121
#7  0x00007ff12c16ed3c in QGuiApplication::exec() () at kernel/qguiapplication.cpp:1870
#8  0x00007ff12cba53c5 in QApplication::exec() () at kernel/qapplication.cpp:2832
#9  0x00005630e4464c19 in main(int, char**) (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/plasma-workspace-5.27.2/shell/main.cpp:235

It also looks in strace like it's polling, so it doesn't seem to be stuck somewhere:
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 1) = 0 (Timeout)
write(3, "\1\0\0\0\0\0\0\0", 8)         = 8
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 4) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 1 ([{fd=4, revents=POLLIN}])
read(4, "\1\0\0\0\0\0\0\0", 16)         = 8
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 0) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 5) = 1 ([{fd=4, revents=POLLIN}])
read(4, "\1\0\0\0\0\0\0\0", 16)         = 8
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 5) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 5) = 1 ([{fd=4, revents=POLLIN}])
read(4, "\1\0\0\0\0\0\0\0", 16)         = 8
statx(AT_FDCWD, "/usr/share/plasma/desktoptheme/default/icons/ktorrent.svgz", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=809, ...}) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+org.kde.desktop", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+sv_SE", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+unix", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+linux", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+opensuse-tumbleweed", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
access("/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/StatusNotifierItem.qml", F_OK) = 0
statx(AT_FDCWD, "/usr/share/plasma/desktoptheme/default/icons/ktorrent.svgz", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=809, ...}) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
newfstatat(AT_FDCWD, "/etc/localtime", {st_mode=S_IFREG|0644, st_size=2298, ...}, 0) = 0
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+org.kde.desktop", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+sv_SE", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+unix", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+linux", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
statx(AT_FDCWD, "/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/+opensuse-tumbleweed", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fffa1f9f300) = -1 ENOENT (Filen eller katalogen finns inte)
access("/usr/share/plasma/plasmoids/org.kde.plasma.private.systemtray/contents/ui/items/StatusNotifierItem.qml", F_OK) = 0
write(4, "\1\0\0\0\0\0\0\0", 8)         = 8
write(4, "\1\0\0\0\0\0\0\0", 8)         = 8
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 0) = 1 ([{fd=4, revents=POLLIN}])
read(4, "\2\0\0\0\0\0\0\0", 16)         = 8
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 4) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 1) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 5) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 5) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 5) = 0 (Timeout)
poll([{fd=4, events=POLLIN}, {fd=22, events=POLLIN}, {fd=23, events=POLLIN}, {fd=59, events=POLLIN}, {fd=73, events=POLLPRI}, {fd=74, events=POLLIN}, {fd=83, events=POLLIN}, {fd=84, events=POLLIN}, {fd=207, events=POLLIN}, {fd=237, events=POLLIN}, {fd=260, events=POLLIN}], 11, 6) = 0 (Timeout)

And I can see it reading stuff from fd 4 in strace if I scroll on the desktop background.

Also, the desktop UI returns if I change the screen resolution, without needing to restart plasmashell.
Comment 6 Nate Graham 2023-03-27 19:02:40 UTC
Thanks. A few weeks ago, I had similar Plasma hangs in statx system calls with early 6.2 kernel versions. But now I'm on 6.2.7 and the issue has completely gone away.

Any chance you could upgrade to that kernel version or a newer one, and see if the issue vanishes?
Comment 7 Linus Kardell 2023-03-28 16:55:27 UTC
Currently on kernel 6.2.8-1-default. Today I had this happen to my right screen, but plasmashell still functions correctly on my left (main) screen.
Comment 8 Nate Graham 2023-03-28 17:22:49 UTC
Perhaps we're on the wrong track here. Can you clarify what exactly happens on the screen that's affected? Can you move the cursor on to that screen? Can you drag windows there and interact with them? If you right-click on the black background, do you get a context menu?
Comment 9 Linus Kardell 2023-03-28 17:38:44 UTC
Yes, can move the cursor and windows to the other monitor and use them there, it's just plasmashell that doesn't display anything on it (and the context menu doesn't work either). It's like plasmashell loses track of the monitor when it goes to powersave, and finds it again when the monitor settings are changed.
Comment 10 Nate Graham 2023-03-29 15:09:37 UTC
Ah, so what happened is that Plasma lost the desktop containment for that screen. We do have a UI to recover them in the form of the "Manage Desktops and Panels" window, which should let people manually restore their old setup. You can access it like so:

Right-click on desktop > click on "Enter Edit Mode" > a toolbar pops down from the top of the screen > click on "Manage Desktops and Panels"

Can you use that window to recover the desktop, move it to the correct monitor, then upgrade to Plasma 5.27.3 and see if it stops happening?
Comment 11 Linus Kardell 2023-04-03 17:56:44 UTC
Created attachment 157824 [details]
Screen management screenshot

I'm already on Plasma 5.27.3 by now.

I don't see anything in "Manage Desktops and Panels" I can use to recover, it shows all but the first screen as disconnected.
Comment 12 Nate Graham 2023-04-04 19:07:13 UTC
Ah, it seems like Plasma itself has missed that you have an external screen connected. So it failed to assign that screen a containment. Clearly you do have such a screen connected though. Looks like KScreen and KWin did their parts and the issue is in Plasma itself.
Comment 13 Marco Martin 2023-04-05 07:53:36 UTC
are the connectors displayport, hdmi or over an usb-c dock?
Comment 14 Linus Kardell 2023-04-05 07:59:28 UTC
They use DisplayPort, directly into the graphics card.
Comment 15 Nate Graham 2023-05-24 17:36:21 UTC
*** Bug 470184 has been marked as a duplicate of this bug. ***
Comment 16 Steve 2023-06-09 16:37:02 UTC
FWIW I am including my display configuration. My docking station has 1 display port and 1 HDMI port. It is the display port that goes to my 4-way HDMI switch (via a display-port to HDMI adapter) and ultimately monitor #3 (32-inch LG). The HDMI port feeds monitor #2 directly (DELL 32") and monitor #1 (internal laptop display) is disabled as I keep the laptop lid closed. It is when I temporarily switch out monitor #3 (and back in again) that I lose Plasma shell functionality on that desktop. I am using XFCE4 Desktop for this laptop until this bug is resolved.
Comment 17 Nate Graham 2023-06-09 20:05:47 UTC
*** Bug 470799 has been marked as a duplicate of this bug. ***
Comment 18 LabHamster 2023-06-09 21:09:43 UTC
Is there any value in me trying to pinpoint the exact version of plasmashell this starts happening in to help narrow down what code change(s) in plasmashell are the contributor(s) if there are already logs? I think I have the same issue. When I have a proper full weekend soon I can rebase my Fedora Kinoite down to 37 I believe and then jump around OSTree commits until I find the two sequencial commits where the first doesn't have this issue, and the second has this issue.
Comment 19 Steve 2023-06-09 23:09:11 UTC
That would be great detective work LabHamster! I would venture that would be much appreciated by the Plasma team.  That would help them immensely in tracking down what changed in Plasma. I can say definitively this is not an issue in Slackware 15.0 (5.23.5) but it is in Slackware current (5.27+). Mine are both x86_64 versions of the distro.
Comment 20 Nate Graham 2023-06-09 23:42:44 UTC
Yes absolutely, that would be hugely impactful! for bugs like these, usually developers can't reproduce it, so knowing exactly which version--or even commit--caused it would be amazing.
Comment 21 Nate Graham 2023-06-10 02:38:44 UTC
I'll mention that if you can narrow it down to a specific git commit, the problem will probably be obvious.
Comment 22 LabHamster 2023-06-18 21:31:26 UTC
Is KDE still patching x11 at this point in time? I'm asking to determine if I should be focusing replication of a healthy state on x11, Wayland, or both as I know some distros like Fedora are planning to be Wayland only w/ Plasma 6.0.0. This ticket mentions x11 and potentially working on 5.27.0, but I tried Wayland on 5.26.5 and still get the all black screen w/ mouse issue. As luck would have it, I was able to update my KDE system HW to use a 2080 Ti w/ proprietary drivers and I have two monitors over DisplayPort, so it's a matter of x11 vs Wayland being the only major factor in trying to replicate a known healthy state of another bug experiencer.

With the following I can replicate this issue, so it doesn't seem like it was working on Wayland in 5.26.5:
Operating System: Fedora Kinoite Linux 37.20230215.0
KDE Plasma Version: 5.26.5
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Kernel Version: 6.1.11-200.fc37.x86_64 (64-bit)
Graphics Platform: Wayland
Graphics Processor: NVIDIA GeForce RTX 2080 Ti/PCIe/SSE2

How to replicate software side to hunt for the release that corresponds to this bug while I continue to experiment to try to find a prior healthy state.

1. Have bug in first place with KDE
2. Install Fedora Kinoite
3. If not on Fedora Kinoite 37 rebase with: rpm-ostree rebase fedora:fedora/37/x86_64/kinoite
4. Iterate through ostree commits using a command like: rpm-ostree deploy 37.20230215.0
5. Reboot after getting to said commit
6. While logged on launch a few apps to see if they vanish later on
7. Try to trigger the bug. For me, it's switching to another system with a KVM switch for period of time and then back to the KDE system. Currently using 5 minutes, but will try to make it smaller and smaller to increase ability to iteration through ostree commits
Comment 23 LabHamster 2023-06-19 00:38:32 UTC
General findings on trying to replicate this:

Issue: Both monitors black with moveable mouse after switching back after 5 min to KDE system via KVM switch. No way to exit out via Ctrl+Alt+Del, etc. Issue fixed by power cycling KDE system with power button until next ~5 min toggle away via KVM switch.
System: Fedora Kinoite 37. Seen with both Nvidia 2080 Ti w/ proprietary drivers and Intel Arc 750. Only used Arc 750 on ostree commits following kernel 6.2.x release

rpm-ostree deploy 37.20221212.0   See Issue after 5 min? Wayland: Yes  x11: ?? Plasma 5.26.4
rpm-ostree deploy 37.20230215.0   See Issue after 5 min? Wayland: Yes  x11: No Plasma 5.26.5
rpm-ostree deploy 37.20230307.0   See Issue after 5 min? Wayland: ??  x11: No Plasma 5.27.2
rpm-ostree deploy 37.20230618.0   See Issue after 5 min? Wayland: Yes  x11: No Plasma 5.27.4

While I can't replicate the bug on x11 as reported by linus.kardell, I do see a similar issue on Wayland which leads me to suspect root cause is similar. Hopefully whatever additional work is done to identify and fix the x11 side of the issue patches Wayland as well before distros start putting out Wayland-only releases.

When I described 470799 as a regression, I may have mispoken as there were several things I changed around late April: GPU (Nvidia 2080 Ti to an Intel Arc) and my messing around with x11 and Wayland to see if MESA was better. Based on my recent testing results across ~4 ostree commits I believe the experience 'regression' I had described was from misremembering my experimenting with x11 and Wayland experiences on Arc, not a code driven regression.

If there's any further testing that I can do to assist with something like a logger, please let me know.
Comment 24 yizel7 2023-06-19 02:22:05 UTC
Unfortunately I am forced to use X11 because nvidia support. I have the same issue where if my laptop with an external monitor is connected via hdmi that goes to a dedicated nvidia chip and the laptop goes to sleep for a while. On wake either none of the screens work (even the built in) or only one works (mostly the external). I then have to alt ctrl f2 3 or whatever and reboot to get my screens back. It is a pretty bad experience and happens daily..........
Comment 25 Steve 2023-06-19 05:07:39 UTC
I can definitively state that in 5.27.5 this is only an issue with Plasma X11. Wayland and Full Wayland on my Slackware64 distro (Current tree) do not exhibit this behavior (bug) with Plasma shell - i.e. losing it's recollection of active monitors after a disconnection or sleep condition. See (my) comment #16 above for more detail on my setup. As I stated in my original bug report 470184 (now marked as duplicate of this bug), this is not an issue with XFCE4 or Windows on my system. This is only an issue on Plasma X11. The behavior we think started sometime after the 5.26.X? release. LabHamster was working on determining a more definitive release # of when Plasma Shell started to exhibit this behavior.
Comment 26 LabHamster 2023-06-19 06:20:34 UTC
So to clarify on my testing from this weekend, my situation is reversed compared to others. I can not replicate this issue on x11 with 5.26.4, 5.26.5, 5.27.2, 5.27.4 like Steve and linus.kardell with the 2080 Ti I have on hand. Because I can not replicate the issue in the first place on x11, there's no way I believe for me to find the breaking release. I have what I think is a form of the issue on at least 5.26.4, 5.26.5, 5.27.2, 5.27.4 on Wayland. However, linus.kardell reports recalling this issue not being present in 5.27.0 (mid-Feb). I on Wayland have found this issue to be present until at least 5.26.4 (mid-Dec), with even further bugs around mouse appearance. I'm open to other test ideas afforded by Fedora Kinoite's use of ostree to better narrow down cause because this is a particularly painful bug for my lab setup, but I don't have any ideas at present for me to execute.

My situation seems closest to yizel's in that on 5.27.5 (and dating back to at least 5.26.4) I see this issue with both Nvidia proprietary and Intel Arc 750 on MESA exclusively on Wayland. The only issue I have on x11 when toggling back to a KDE system via KVM switch after being 'away' for 5+ minutes is sometimes all app windows get wiped, but it's not consistent like black monitors with Wayland. I believe I saw that clearing symptom being patched for 5.27.6 sometime in the last month in Nate's weekly blog, but it seems unrelated in nature to this screen suspend type bug
Comment 27 Steve 2023-06-19 17:54:10 UTC
I managed to find an installation image (.iso) from February 6th (2023). This version of Slackware64 has the following KDE5 versions:
Core Desktop binaries: 5.26.5
Frameworks: 5.102.0
Applications: 22.12.2
I recently bought an external 1TB SSD and installed this version of the OS/Desktop Environment on my laptop. These versions do not exhibit the behavior when switching in/out the secondary desktop as it does in the more recent versions of Plasma X11.  This should narrow down the code changes sufficiently in the plasma-desktop (and workspace) packages to a workable window for the bug-fixers. Happy bug-fixing to the KDE Team! I am confident your very capable developers can quickly resolve and fix the bug now.
Comment 28 Steve 2023-09-04 16:14:52 UTC
This is still an issue in 5.27.7. Although there seems to be new behavior - or at least I didn't notice there was a timeout dependency before. On my setup I can now cycle through my 3 other systems (via KVM Switch) and avoid the death of plasma shell if I do it quickly. It looks to be about 1 minute before it dies. I am happy to run some debugging for the developers if this is useful.
Comment 29 Steve 2023-10-26 13:29:38 UTC
I just upgraded my kde packages with the hope that this bug would be fixed by now. My hopes are dashed once again. The behavior still persists with the following versions in slackware64 (current branch):
Core Desktop binaries: 5.27.9
Frameworks: 5.111.0
Applications: 23.08.2
@Nate, I am happy to run further experiments, collect logs and/other debug for the developers. I cannot say with confidence that there is motivation to fix/address this bug with no activity since May of last year.
Comment 30 Harald Sitter 2023-11-06 20:21:53 UTC
Can anyone still reproduce this without KVM switch or MST devices?

Also it'd be grand if everyone could attach a complete journalctl output from the time power management kicks in to the time you see the black background.

Also, can you all reproduce this with a pristine new user without any extra display configuration? If not, what configuration do you have to do to trigger the issue?
Comment 31 Bug Janitor Service 2023-11-21 03:45:44 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 32 Bug Janitor Service 2023-12-06 03:45:50 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!
Comment 33 LabHamster 2023-12-07 06:12:34 UTC Comment hidden (spam)
Comment 34 Nate Graham 2023-12-07 06:31:45 UTC Comment hidden (spam)
Comment 35 Steve 2023-12-07 14:18:56 UTC
I figured a work around on my KVM switch but this is still a bug AFAIAC. My dual-monitor system has one monitor fed with a DVI port and the other with an HDMI port (through the laptop docking interface). The initial configuration had the DVI port routed through the KVM switch and the HDMI port routed to a dedicated monitor (non-shared). It dawned on me that by switching the ports so that the HDMI was the port being 
 routed through the KVM switch it might resolve the issue. Sure enough this was the case. The initial configuration worked just fine in XFCE4 and Plasma Wayland so it should also work in Plasma X11. It still doesn't work even with the latest Plasma version 5.27.10.
Comment 36 Nate Graham 2024-02-07 02:56:50 UTC
If anyone CCd on this bug report is testing the Plasma 6 RC and would re-test the issue, that would be lovely. We've made a ton of multi-monitor improvements in Plasma 6, and it's possible it's been fixed.

Note: this bug is reported to only happen on X11, so I'm interested in knowing if it's fixed there, but regardless, I recommend using the Wayland session if you want a good multi-monitor experience.
Comment 37 Steve 2024-02-10 00:17:36 UTC
Happy to try out the 6 RC packages Nate. I'll put a request into the current release group on LQ to have the packages built and put into /testing.
Comment 38 Nate Graham 2024-02-13 17:22:34 UTC
Thanks! If you could also test it, Linus, that would be great. If not, well, the final release is in two weeks so I guess we don't have to long to wait. :)
Comment 39 Linus Kardell 2024-02-14 10:22:08 UTC
I'll see once it hits OpenSUSE Tumbleweed. Though I don't recall seeing this issue for some time now.
Comment 40 Bug Janitor Service 2024-02-29 03:46:26 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 41 Bug Janitor Service 2024-03-15 03:46:50 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!