Plasma-shell crashes right after login (likely a race condition)

For some odd reason my plasma-shell crashes right after login and the opens successfully. This is either a bug in the NVIDIA drivers, plasma or Qt 6.10.x. This also happens on my laptop whenever I login and have the NVIDIA drivers loaded. Whenever the NVIDIA drivers are not loaded the crash does not occur.

From what I could quickly gather is that xdg-activation and data_offer protocol errors with explicit sync ENABLED show an unresolved initialization race condition. The invalid object ID 0xFEED0011 during protocol initialization seem to be unique (couldn’t find it anywhere so far).

I’ve also created plasma bug: https://bugs.kde.org/show_bug.cgi?id=515786

nvidia-bug-report.log.gz (481.5 KB)

crash-21-39-analysis.tar.gz (1.5 MB)

This file contains the crash analysis which I ran on my desktop with QT debug mode enabled.

Other things I’ve tried and that didn’t work:

  • The NVIDIA drivers in the 570 and 580 series.
  • Downgrading libdrm and downgrading mesa
  • Changing from CSD to SSD: This made the “QWaylandGLContext: Failed to create the decorations EGLContext. Decorations will not be drawn” go away, but it gave eglSwapBuffers failed with 0x3000 instead and it still crashed with the exact same error: The Wayland connection experienced a fatal error: Invalid argument. I ended up reverting this.
  • Upgrading from Qt version 6.10.1 to 6.10.2 (This seem to have made the QWaylandGLContext: Failed to create the decorations EGLContext. Decorations will not be drawn go away)
  • Upgrading egl-gbm and egl-wayland to their latest version
  • Using egl-wayland2 instead of egl-wayland

If anything else is needed, then please don’t hesitate and let me know.

I’m running Gentoo, so I can re-compile packages relatively easily with debug symbols if needed and run things through ggdb for testing.

Note: PC names might be different, but that’s cause I’m busy with other things on the same system. If there’s a deviating username, it’s because I tested this with a clean user, to make sure it’s not config related.