Bug 433976 - App Crashes Upon Start
Summary: App Crashes Upon Start
Status: RESOLVED FIXED
Alias: None
Product: plasma-systemmonitor
Classification: Applications
Component: general (other bugs)
Version First Reported In: 5.21.2
Platform: Arch Linux Linux
: NOR crash
Target Milestone: ---
Assignee: KSysGuard Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-03-05 00:06 UTC by TheNormGuy
Modified: 2021-03-10 12:41 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description TheNormGuy 2021-03-05 00:06:20 UTC
SUMMARY
The current version of plasma-systemmonitor (5.21.2-1) on the current build of Arch Linux (5.10.16-arch1-1) does not launch and crashes upon start.

STEPS TO REPRODUCE
1. Open plasma-systemmonitor from the console or app shortcut.

OBSERVED RESULT
The application crahses.

EXPECTED RESULT
The app opens and functions as intended.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
KDE Plasma Version: 5.21.2
KDE Frameworks Version: 5.79.0
Qt Version: 5.15.2
Graphics Platform: X11

BACKTRACE
Application: System Monitor (plasma-systemmonitor), signal: Aborted

[KCrash Handler]
#4  0x00007fed04260ef5 in raise () at /usr/lib/libc.so.6
#5  0x00007fed0424a862 in abort () at /usr/lib/libc.so.6
#6  0x00007fed0465e9ac in  () at /usr/lib/libQt5Core.so.5
#7  0x00007fecfb639a79 in QSGRenderLoop::handleContextCreationFailure(QQuickWindow*) () at /usr/lib/libQt5Quick.so.5
#8  0x00007fecfb63afe0 in  () at /usr/lib/libQt5Quick.so.5
#9  0x00007fecfb63c7da in  () at /usr/lib/libQt5Quick.so.5
#10 0x00007fed04cf1b95 in QWindow::event(QEvent*) () at /usr/lib/libQt5Gui.so.5
#11 0x00007fed053d3752 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#12 0x00007fed04883a2a in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib/libQt5Core.so.5
#13 0x00007fed04ce6a20 in QGuiApplicationPrivate::processExposeEvent(QWindowSystemInterfacePrivate::ExposeEvent*) () at /usr/lib/libQt5Gui.so.5
#14 0x00007fed04cbabb5 in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Gui.so.5
#15 0x00007fed00aff16c in  () at /usr/lib/libQt5XcbQpa.so.5
#16 0x00007fed032ddb84 in g_main_context_dispatch () at /usr/lib/libglib-2.0.so.0
#17 0x00007fed03331c21 in  () at /usr/lib/libglib-2.0.so.0
#18 0x00007fed032dc3b1 in g_main_context_iteration () at /usr/lib/libglib-2.0.so.0
#19 0x00007fed048dc691 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Core.so.5
#20 0x00007fed048823ac in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Core.so.5
#21 0x00007fed0488a844 in QCoreApplication::exec() () at /usr/lib/libQt5Core.so.5
#22 0x00005594f13c72a4 in  ()
#23 0x00007fed0424bb25 in __libc_start_main () at /usr/lib/libc.so.6
#24 0x00005594f13c777e in  ()
[Inferior 1 (process 32695) detached]
Comment 1 David Edmundson 2021-03-05 08:12:55 UTC
QSGRenderLoop::handleContextCreationFailure(QQuickWindow*)

Gl drivers broken. This is a setup issue.

But we should be falling back to software, we need to copy that line from kdeclarative.
Comment 2 TheNormGuy 2021-03-05 08:16:08 UTC
Adding additional information from when run from the console -

file:///usr/lib/qt/qml/org/kde/ksysguard/page/EditablePage.qml?page=overview.page:15:1: QML EditablePage: Binding loop detected for property "heightForContent"
file:///usr/lib/qt/qml/org/kde/kirigami.2/private/globaltoolbar/PageRowGlobalToolBarUI.qml:65:9: QML RowLayout (parent or ancestor of QQuickLayoutAttached): Binding loop detected for property "maximumWidth"
file:///usr/lib/qt/qml/org/kde/kirigami.2/private/globaltoolbar/PageRowGlobalToolBarUI.qml:65:9: QML RowLayout (parent or ancestor of QQuickLayoutAttached): Binding loop detected for property "maximumWidth"
qt.qpa.xcb: QXcbConnection: XCB error: 5 (BadAtom), sequence: 632, resource id: 0, major code: 20 (GetProperty), minor code: 0
file:///usr/lib/qt/qml/org/kde/kirigami.2/private/globaltoolbar/PageRowGlobalToolBarUI.qml:65:9: QML RowLayout (parent or ancestor of QQuickLayoutAttached): Binding loop detected for property "maximumWidth"
file:///usr/lib/qt/qml/QtQuick/Controls.2/org.kde.desktop/ScrollView.qml:99:27: QML ScrollBar: Binding loop detected for property "visible"
TableView::forceLayout(): Cannot do an immediate re-layout during an ongoing layout!
file:///usr/lib/qt/qml/QtQuick/Controls.2/org.kde.desktop/ScrollView.qml:99:27: QML ScrollBar: Binding loop detected for property "visible"
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.piechart/contents/ui/PieChart.qml:91:9: Unable to assign [undefined] to double
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.piechart/contents/ui/PieChart.qml:91:9: Unable to assign [undefined] to double
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.piechart/contents/ui/PieChart.qml:91:9: Unable to assign [undefined] to double
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
file:///usr/share/ksysguard/sensorfaces/org.kde.ksysguard.textonly/contents/ui/GroupedText.qml:83:21: Unable to assign [undefined] to QColor
Comment 3 Nate Graham 2021-03-05 14:58:16 UTC
> QSGRenderLoop::handleContextCreationFailure
Well that wasn't supposed to happen. I thought we fixed all of these with https://invent.kde.org/frameworks/kdeclarative/commit/090610124d4650150af49a8e30f6b77ad9803dfe.

Is system monitor not using KQuickAddons::QtQuickSettings::init(), maybe?
Comment 4 Arjen Hiemstra 2021-03-09 11:20:50 UTC
> But we should be falling back to software, we need to copy that line from kdeclarative.

No, we should not. Not until Quick Charts has support for software fallback, which is going to be a long time since I found out from ShadowedRectangle in Kirigami there is actually no way to do software fallback for custom scene graph items. Without that, plasma-systemmonitor is just going to look broken so I'd rather just have it quit on start if OpenGL fails.
Comment 5 David Edmundson 2021-03-09 12:32:20 UTC
It's 

`QT_QUICK_BACKEND=software plasma-systemmonitor   `

With the stock homepage you still get a box on the homepage with:
"Memory 5.9GiB" and whatnot. 

The applications view is surprisingly performant.

Obviously we don't get the graphs and such, but the functionality is ok. That somewhat matches the plasmashell experience, and we don't get many bug reports.

It's obviously degraded and we might want a visible warning, but I would suggest reconsidering if we want to replace ksysguard.


>there is actually no way to do software fallback for custom scene graph items. 

FWIW, You can do things at a node level.

Create a QImage, draw into it, then do window()->createTextureFromImage()
window()->createImageNode()  . Return that object.

We did that somewhere.

It means an intermediate cache, but that's potentially a good thing.
Comment 6 Arjen Hiemstra 2021-03-10 12:41:44 UTC
Git commit 955948e28f2bb4c6551d7a6662e1d5527b3d8e9b by Arjen Hiemstra.
Committed on 10/03/2021 at 12:41.
Pushed by ahiemstra into branch 'master'.

Use software rendering if we cannot use OpenGL and complain about it

Use KQuickAddons::QtQuickSettings to fallback to software rendering if
OpenGL context creation fails. When using software rendering, we display
a message at the top of the window that complains about it.

M  +1    -0    src/CMakeLists.txt
M  +3    -2    src/main.cpp
M  +15   -0    src/main.qml

https://invent.kde.org/plasma/plasma-systemmonitor/commit/955948e28f2bb4c6551d7a6662e1d5527b3d8e9b