KWin has some internal logic to disable compositing automatically after certain issues happen, and it sets OpenGLIsUnsafe=true in the user's ~/.config/kwinrc file. This is fairly heavy-handed solution that makes the system seem broken and generates bug reports. For example: - https://bugs.kde.org/show_bug.cgi?id=452193 - https://bugs.kde.org/show_bug.cgi?id=446779 - https://bugs.kde.org/show_bug.cgi?id=431161 We should try to avoid this if possible. If it's not possible, we need to be more proactive about telling the user what happened and letting them now how they can fix it. Sending a persistent system notification could work.
*** Bug 431161 has been marked as a duplicate of this bug. ***
*** Bug 446779 has been marked as a duplicate of this bug. ***
*** Bug 452193 has been marked as a duplicate of this bug. ***
*** Bug 432038 has been marked as a duplicate of this bug. ***
*** Bug 457384 has been marked as a duplicate of this bug. ***
Raising priority since this makes the system seem super broken when it happens.
*** Bug 458372 has been marked as a duplicate of this bug. ***
The more important issue isn't to show a notification but to make us try again. Especially for the case of just a bad driver + kernel combo. We can compare the system boot time, and try again the next boot.
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/2992
Git commit 9a6c1e60e84f83f9f42f1b1519fe0964b8daf445 by Arjen Hiemstra. Committed on 27/09/2022 at 10:23. Pushed by vladz into branch 'master'. X11 backend: Retry enabling compositing when it was disabled a while ago This removes the "OpenGLIsUnsafe" flag and replaces it with a timestamp that we can check to see how long ago we tried enabling compositing, so we can retry it if a certain amount of time has elapsed. M +16 -8 src/backends/x11/standalone/x11_standalone_platform.cpp M +2 -2 src/kcmkwin/kwincompositing/kwincompositing_setting.kcfg M +1 -1 src/kcmkwin/kwincompositing/kwincompositingdata.cpp M +2 -2 src/kcmkwin/kwincompositing/main.cpp M +3 -0 src/kwin.kcfg https://invent.kde.org/plasma/kwin/commit/9a6c1e60e84f83f9f42f1b1519fe0964b8daf445
Git commit 8d0be8e469dff0ce409f491b0a62cb428e277190 by Vlad Zahorodnii, on behalf of Arjen Hiemstra. Committed on 27/09/2022 at 11:01. Pushed by vladz into branch 'Plasma/5.26'. X11 backend: Retry enabling compositing when it was disabled a while ago This removes the "OpenGLIsUnsafe" flag and replaces it with a timestamp that we can check to see how long ago we tried enabling compositing, so we can retry it if a certain amount of time has elapsed. (cherry picked from commit 9a6c1e60e84f83f9f42f1b1519fe0964b8daf445) M +16 -8 src/backends/x11/standalone/x11_standalone_platform.cpp M +2 -2 src/kcmkwin/kwincompositing/kwincompositing_setting.kcfg M +1 -1 src/kcmkwin/kwincompositing/kwincompositingdata.cpp M +2 -2 src/kcmkwin/kwincompositing/main.cpp M +3 -0 src/kwin.kcfg https://invent.kde.org/plasma/kwin/commit/8d0be8e469dff0ce409f491b0a62cb428e277190
Git commit b30e81cb22d604146a20ca556b14018dd9a98bf2 by Vlad Zahorodnii. Committed on 28/10/2022 at 09:38. Pushed by vladz into branch 'master'. x11: Keep compositing mode untouched if kwin crashes kwin can crash for reasons that have nothing to do with compositing. If that's the case, after two crashes compositing will be permanently disabled and you would need to go to system settings to reenable it, the timestamp based check in the x11 backend won't be effective. M +0 -6 src/main_x11.cpp https://invent.kde.org/plasma/kwin/commit/b30e81cb22d604146a20ca556b14018dd9a98bf2