repos-holder / kdecoration2-kde2

6 stars 1 forks source link

systemsettings appearance module crashes with kdecoration2-kde2 installed #5

Open cbxd82 opened 1 year ago

cbxd82 commented 1 year ago

Hello,

I would like to thank you first for your work at porting KDE2 decoration to Plasma 5. I have been using it for several years now and will not change.

There is an issue while trying to set the decoration with Qt 5.15.5, KF 5.95 and Plasma 5.25.2.

The install process runs without errors with cmake and make install. However. when I try to set the decoration in System Settings, there is inevitably a crash just after trying to open the "Appearance" module. This happens in both Arch Linux and Alpine Linux. This will not happen with previous versions of KF and Plasma (5.95 and 5.24.5, respectively).

Here are the steps to reproduce the error in Plasma 5.25.2 with KF 5.95 and built against Qt 5.15.5 : 1- Install kdedecoration2 as usual 2- Next, open System Settings and click on "Appearance" >> System Settings crashes (no dialog at all)

To see the error, you have to run systemsettings5 from the command line. Here is the error generated by the crash while trying to access the "Appearance" module :

file:///usr/share/kpackage/kcms/kcm_lookandfeel/contents/ui/main.qml:84:9: QML StackView: Binding loop detected for property "implicitHeight"
file:///usr/share/kpackage/kcms/kcm_style/contents/ui/main.qml:38:13: QML ColumnLayout: Cannot anchor to an item that isn't a parent or sibling.
file:///usr/share/kpackage/kcms/kcm_desktoptheme/contents/ui/main.qml:58:14: QML RowLayout: Cannot anchor to an item that isn't a parent or sibling.
file:///usr/lib/qt5/qml/org/kde/kcm/AbstractKCM.qml:60:13: QML Control: Binding loop detected for property "implicitHeight"
file:///usr/share/kpackage/kcms/kcm_colors/contents/ui/main.qml:293:25: Unable to assign [undefined] to bool
file:///usr/share/kpackage/kcms/kcm_colors/contents/ui/main.qml:85:13: QML ColumnLayout: Cannot anchor to an item that isn't a parent or sibling.
kf.kirigami: Units.devicePixelRatio is deprecated (since 5.86): This returns 1 when using Qt HiDPI scaling.
Using fontconfig file: "/home/chris/.fonts.conf"
file:///usr/lib/qt5/qml/org/kde/kirigami.2/FormLayout.qml:281:9: QML QQuickItem* (parent or ancestor of QQuickLayoutAttached): Binding loop detected for property "preferredWidth"
file:///usr/lib/qt5/qml/org/kde/kirigami.2/FormLayout.qml:281:9: QML QQuickItem* (parent or ancestor of QQuickLayoutAttached): Binding loop detected for property "preferredWidth"
file:///usr/share/kpackage/kcms/kcm_icons/contents/ui/main.qml:207:13: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onFoo(<arguments>) { ... }
file:///usr/share/kpackage/kcms/kcm_splashscreen/contents/ui/main.qml:29:13: QML ColumnLayout: Cannot anchor to an item that isn't a parent or sibling.
kf.coreaddons: KPluginFactory could not create a KDecoration2::DecorationThemeProvider instance from "/usr/lib/qt5/plugins/org.kde.kdecoration2/breezedecoration.so"
kf.coreaddons: KPluginFactory could not create a KDecoration2::DecorationThemeProvider instance from "/usr/lib/qt5/plugins/org.kde.kdecoration2/kde2_decoration.so"
ASSERT: "it.value().toString() == QLatin1String("KDE 2")" in file /home/chris/build/kdecoration2-kde2/src/skeleton.cpp, line 270
Aborted

As I am no developer, I don't know how to solve it. Anyone else having this issue? Please tell me if you need more information or any help.

All the best, Christophe

poudink commented 1 year ago

Comment out lines 269-272 from skeleton.cpp. This seems to have the side effect of changing the theme's name to org.kde.kde2, but it fixes the crash and allows for the decoration to be used.

mathieujobin commented 1 year ago

I have similar issue, I will try commenting the lines 269:272 ...

here is the stacktrace

Application: System Settings (systemsettings), signal: Aborted

[KCrash Handler]
#4  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
#5  __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
#6  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
#7  0x00007f132823bc46 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#8  0x00007f13282227fc in __GI_abort () at ./stdlib/abort.c:79
#9  0x00007f1328a90caf in QMessageLogger::fatal(char const*, ...) const () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#10 0x00007f1328a90020 in qt_assert(char const*, char const*, int) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#11 0x00007f12e47164ff in Skeleton::Decoration::Decoration (this=0x56102a786160, parent=0x0, args=...) at /home/mathieu/projects/opensource/KDE/kdecoration2-kde2/src/skeleton.cpp:270
#12 0x00007f12e471fe9b in KPluginFactory::createInstance<Skeleton::Decoration, QObject> (parentWidget=0x0, parent=0x0, args=...) at /usr/include/KF5/KCoreAddons/kpluginfactory.h:891
#13 0x00007f1329fc2933 in KPluginFactory::create(char const*, QWidget*, QObject*, QList<QVariant> const&, QString const&) () from /lib/x86_64-linux-gnu/libKF5CoreAddons.so.5
#14 0x00007f12e481113d in ?? () from /usr/lib/x86_64-linux-gnu/qt5/qml/org/kde/kwin/private/kdecoration/libkdecorationprivatedeclarative.so
#15 0x00007f12e4813484 in ?? () from /usr/lib/x86_64-linux-gnu/qt5/qml/org/kde/kwin/private/kdecoration/libkdecorationprivatedeclarative.so
#16 0x00007f12e481980a in ?? () from /usr/lib/x86_64-linux-gnu/qt5/qml/org/kde/kwin/private/kdecoration/libkdecorationprivatedeclarative.so
#17 0x00007f1326b00943 in QQmlObjectCreator::finalize(QQmlInstantiationInterrupt&) () from /lib/x86_64-linux-gnu/libQt5Qml.so.5
#18 0x00007f1326a95f32 in QQmlIncubatorPrivate::incubate(QQmlInstantiationInterrupt&) () from /lib/x86_64-linux-gnu/libQt5Qml.so.5
#19 0x00007f1326a963d5 in QQmlEnginePrivate::incubate(QQmlIncubator&, QQmlContextData*) () from /lib/x86_64-linux-gnu/libQt5Qml.so.5
#20 0x00007f132452ebef in ?? () from /lib/x86_64-linux-gnu/libQt5QmlModels.so.5
#21 0x00007f13271266a4 in ?? () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#22 0x00007f13271182f5 in ?? () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#23 0x00007f1327124e93 in ?? () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#24 0x00007f132711d169 in ?? () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#25 0x00007f13270d4847 in QQuickFlickablePrivate::itemGeometryChanged(QQuickItem*, QQuickGeometryChange, QRectF const&) () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#26 0x00007f1327123fdd in ?? () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#27 0x00007f132705ad13 in QQuickItem::geometryChanged(QRectF const&, QRectF const&) () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#28 0x00007f13270587e0 in QQuickItem::setY(double) () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#29 0x00007f13270d506d in QQuickFlickablePrivate::setViewportY(double) () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#30 0x00007f1328cf36ff in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#31 0x00007f1321feee7c in QQuickScrollBar::setPosition(double) () from /lib/x86_64-linux-gnu/libQt5QuickTemplates2.so.5
#32 0x00007f1321fb755d in QQuickControl::mouseMoveEvent(QMouseEvent*) () from /lib/x86_64-linux-gnu/libQt5QuickTemplates2.so.5
#33 0x00007f1327061cc8 in QQuickItem::event(QEvent*) () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#34 0x00007f132996bf32 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#35 0x00007f1328cbae38 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#36 0x00007f132707fbee in QQuickWindowPrivate::deliverMouseEvent(QQuickPointerMouseEvent*) () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#37 0x00007f13270812ed in QQuickWindowPrivate::deliverPointerEvent(QQuickPointerEvent*) () from /lib/x86_64-linux-gnu/libQt5Quick.so.5
#38 0x00007f132914eaa5 in QWindow::event(QEvent*) () from /lib/x86_64-linux-gnu/libQt5Gui.so.5
#39 0x00007f132996bf32 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#40 0x00007f1328cbae38 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#41 0x00007f1327b4aa7b in QQuickWidget::mouseMoveEvent(QMouseEvent*) () from /lib/x86_64-linux-gnu/libQt5QuickWidgets.so.5
#42 0x00007f13299aeb48 in QWidget::event(QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#43 0x00007f132996bf32 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#44 0x00007f13299745b2 in QApplication::notify(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#45 0x00007f1328cbae38 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#46 0x00007f13299726b2 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#47 0x00007f13299c80dc in ?? () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#48 0x00007f13299cb4a0 in ?? () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#49 0x00007f132996bf32 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#50 0x00007f1328cbae38 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#51 0x00007f13291426fd in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () from /lib/x86_64-linux-gnu/libQt5Gui.so.5
#52 0x00007f132911663c in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib/x86_64-linux-gnu/libQt5Gui.so.5
#53 0x00007f132395078e in ?? () from /lib/x86_64-linux-gnu/libQt5XcbQpa.so.5
#54 0x00007f13275224f9 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#55 0x00007f1327577228 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#56 0x00007f132751fcb0 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#57 0x00007f1328d14aea in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#58 0x00007f1328cb97cb in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#59 0x00007f1328cc1c2a in QCoreApplication::exec() () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#60 0x000056102614e3f9 in ?? ()
#61 0x00007f1328223510 in __libc_start_call_main (main=main@entry=0x56102614d8d0, argc=argc@entry=1, argv=argv@entry=0x7fffbc0178b8) at ../sysdeps/nptl/libc_start_call_main.h:58
#62 0x00007f13282235c9 in __libc_start_main_impl (main=0x56102614d8d0, argc=1, argv=0x7fffbc0178b8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fffbc0178a8) at ../csu/libc-start.c:381
#63 0x000056102614ed45 in ?? ()
[Inferior 1 (process 1330350) detached]
mathieujobin commented 1 year ago

I confirm, the bug is gone when I commented out the lines and rebuild. I can now use it.

mescobal commented 4 months ago

I confirm bug is gone. But I commented 269-271 because if I comment 272 it leaves out a closing bracket. Using Debaian testing, KDE Plasma 5.27.10, QT 5.15.10