Bug 485386 - Fat fingered something around the Ctrl+Alt+Fn keys and plasma crashed in HistoryModel::~HistoryModel()
Summary: Fat fingered something around the Ctrl+Alt+Fn keys and plasma crashed in Hist...
Status: RESOLVED UPSTREAM
Alias: None
Product: plasmashell
Classification: Plasma
Component: Clipboard widget & pop-up (show other bugs)
Version: 6.0.3
Platform: Arch Linux Linux
: NOR crash
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords: drkonqi
: 492008 492185 492809 (view as bug list)
Depends on:
Blocks:
 
Reported: 2024-04-11 16:27 UTC by Timothee Besset
Modified: 2024-09-12 14:33 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed In: Qt 6.7.3
Sentry Crash Report:


Attachments
New crash information added by DrKonqi (133.05 KB, text/plain)
2024-04-11 16:27 UTC, Timothee Besset
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Timothee Besset 2024-04-11 16:27:41 UTC
Application: plasmashell (6.0.3)

Qt Version: 6.6.3
Frameworks Version: 6.0.0
Operating System: Linux 6.8.4-arch1-1 x86_64
Windowing System: X11
Distribution: "Arch Linux"
DrKonqi: 6.0.3 [CoredumpBackend]

-- Information about the crash:
While trying to Alt-Tab something, I fat fingered and may have pressed Alt+Fn+TAB or similar, and plasma shutdown.

This happens every now and then unfortunately, and I lose my entire desktop and any not saved work. Pretty painful when I would normally run a session with connected hosts and running shell processes for weeks on end.

The reporter is unsure if this crash is reproducible.

-- Backtrace (Reduced):
#5  0x00007121e61c9030 in typeinfo for QMilankovicCalendar () at /usr/lib/libQt6Core.so.6
#6  0x00007121e5f3b1e3 in QAbstractProxyModel::roleNames (this=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/itemmodels/qabstractproxymodel.cpp:556
#7  0x00007121e4cb615d in QQmlDelegateModel::_q_modelAboutToBeReset (this=0x6403b31fbf10) at /usr/src/debug/qt6-declarative/qtdeclarative-everywhere-src-6.6.3/src/qmlmodels/qqmldelegatemodel.cpp:1866
#8  0x00007121e5d91599 in QtPrivate::QSlotObjectBase::call (a=0x7ffdd0a56540, r=0x6403b31fbf10, this=0x6403b35fac90, this=<optimized out>, r=<optimized out>, a=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobjectdefs_impl.h:433
#9  doActivate<false> (sender=0x6403b2f5cc00, signal_index=20, argv=0x7ffdd0a56540) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:4039


Reported using DrKonqi
Comment 1 Timothee Besset 2024-04-11 16:27:42 UTC
Created attachment 168397 [details]
New crash information added by DrKonqi

DrKonqi auto-attaching complete backtrace.
Comment 2 Nate Graham 2024-04-12 17:57:06 UTC
Thread 1 (Thread 0x7121e0e351c0 (LWP 1952)):
[KCrash Handler]
#5  0x00007121e61c9030 in typeinfo for QMilankovicCalendar () at /usr/lib/libQt6Core.so.6
#6  0x00007121e5f3b1e3 in QAbstractProxyModel::roleNames (this=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/itemmodels/qabstractproxymodel.cpp:556
#7  0x00007121e4cb615d in QQmlDelegateModel::_q_modelAboutToBeReset (this=0x6403b31fbf10) at /usr/src/debug/qt6-declarative/qtdeclarative-everywhere-src-6.6.3/src/qmlmodels/qqmldelegatemodel.cpp:1866
#8  0x00007121e5d91599 in QtPrivate::QSlotObjectBase::call (a=0x7ffdd0a56540, r=0x6403b31fbf10, this=0x6403b35fac90, this=<optimized out>, r=<optimized out>, a=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobjectdefs_impl.h:433
#9  doActivate<false> (sender=0x6403b2f5cc00, signal_index=20, argv=0x7ffdd0a56540) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:4039
#10 0x00007121e5f1e491 in QAbstractItemModel::modelAboutToBeReset (_t1=..., this=<optimized out>) at /usr/src/debug/qt6-base/build/src/corelib/Core_autogen/include/moc_qabstractitemmodel.cpp:1405
#11 QAbstractItemModel::beginResetModel (this=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/itemmodels/qabstractitemmodel.cpp:3396
#12 0x00007121e5f5442b in QSortFilterProxyModel::setSourceModel (this=0x6403b2f5cc00, sourceModel=0x0) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/itemmodels/qsortfilterproxymodel.cpp:2036
#13 0x00007121c3fe0d2f in KSortFilterProxyModel::setSourceModel (this=0x6403b2f5cc00, model=0x0) at /usr/src/debug/kitemmodels/kitemmodels-6.0.0/src/qml/ksortfilterproxymodel.cpp:94
#14 0x00007121e5f38b2f in QAbstractProxyModelPrivate::setModelForwarder (sourceModel=0x0, this=0x6403b2f692b0) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/itemmodels/qabstractproxymodel_p.h:28
#15 QObjectCompatProperty<QAbstractProxyModelPrivate, QAbstractItemModel*, &QAbstractProxyModelPrivate::_qt_property_model_offset, &QAbstractProxyModelPrivate::setModelForwarder, &QAbstractProxyModelPrivate::modelChangedForwarder, &(QAbstractProxyModelPrivate::getModelForwarder() const)>::bindingWrapper (type=..., dataPtr=0x6403b2f69380, binding=...) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qproperty_p.h:534
#16 0x00007121e5d8ef3c in QPropertyBindingPrivate::evaluateRecursive_inline (status=0x7121e0e35140, bindingObservers=..., this=0x6403b3576300) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qproperty_p.h:854
#17 QPropertyBindingPrivate::evaluateRecursive (this=this@entry=0x6403b3576300, bindingObservers=..., status=0x7121e0e35140, status@entry=0x0) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qproperty.cpp:321
#18 0x00007121e6ef4946 in QQmlPropertyBindingJS::expressionChanged (this=0x6403b35763c0) at /usr/src/debug/qt6-declarative/qtdeclarative-everywhere-src-6.6.3/src/qml/qml/qqmlpropertybinding.cpp:156
#19 0x00007121e6ed21e7 in QQmlNotifier::emitNotify (endpoint=<optimized out>, a=0x0) at /usr/src/debug/qt6-declarative/qtdeclarative-everywhere-src-6.6.3/src/qml/qml/qqmlnotifier.cpp:70
#20 0x00007121e5d913ca in doActivate<false> (sender=0x6403b322c510, signal_index=4, argv=0x0) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:3931
#21 0x00007121e6eddccc in QQmlOpenMetaObject::checkedSetValue (force=<optimized out>, value=..., index=0, this=0x6403b322c530) at /usr/src/debug/qt6-declarative/qtdeclarative-everywhere-src-6.6.3/src/qml/qml/qqmlopenmetaobject.cpp:300
#22 QQmlOpenMetaObject::checkedSetValue (this=0x6403b322c530, index=0, value=..., force=<optimized out>) at /usr/src/debug/qt6-declarative/qtdeclarative-everywhere-src-6.6.3/src/qml/qml/qqmlopenmetaobject.cpp:294
#23 0x00007121e6f60007 in QQmlPropertyMap::clear (this=<optimized out>, key=<optimized out>) at /usr/src/debug/qt6-declarative/qtdeclarative-everywhere-src-6.6.3/src/qml/util/qqmlpropertymap.cpp:167
#24 0x00007121e5d91599 in QtPrivate::QSlotObjectBase::call (a=0x7ffdd0a58ef0, r=0x6403b322c510, this=0x6403b324eb20, this=<optimized out>, r=<optimized out>, a=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobjectdefs_impl.h:433
#25 doActivate<false> (sender=0x7121d8026690, signal_index=0, argv=0x7ffdd0a58ef0) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:4039
#26 0x00007121e5d817d5 in QObject::destroyed (_t1=0x7121d8026690, this=0x7121d8026690) at /usr/src/debug/qt6-base/build/src/corelib/kernel/moc_qobject.cpp:272
#27 QObject::~QObject (this=0x7121d8026690, this=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:1061
#28 0x00007121c01d8b84 in HistoryModel::~HistoryModel (this=0x7121d8026690, this=<optimized out>) at /usr/src/debug/plasma-workspace/plasma-workspace-6.0.3/klipper/historymodel.cpp:22
#29 HistoryModel::~HistoryModel (this=0x7121d8026690, this=<optimized out>) at /usr/src/debug/plasma-workspace/plasma-workspace-6.0.3/klipper/historymodel.cpp:22
#30 0x00007121e5d7cfeb in QObjectPrivate::deleteChildren (this=this@entry=0x6403b3251f10) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:2207
#31 0x00007121e5d81828 in QObject::~QObject (this=<optimized out>, this=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:1159
#32 0x00007121dcc2a28e in Plasma5Support::DataContainer::~DataContainer (this=0x6403b3254790, this=<optimized out>) at /usr/src/debug/plasma5support/plasma5support-6.0.3/src/plasma5support/datacontainer.cpp:28
#33 0x00007121e5d7cfeb in QObjectPrivate::deleteChildren (this=this@entry=0x6403b322cd30) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:2207
#34 0x00007121e5d81828 in QObject::~QObject (this=this@entry=0x6403b322dea0, this=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qobject.cpp:1159
#35 0x00007121dcc2a08f in Plasma5Support::DataEngine::~DataEngine (this=this@entry=0x6403b322dea0, this=<optimized out>) at /usr/src/debug/plasma5support/plasma5support-6.0.3/src/plasma5support/dataengine.cpp:51
#36 0x00007121c01c4f98 in ClipboardEngine::~ClipboardEngine (this=0x6403b322dea0, this=<optimized out>) at /usr/src/debug/plasma-workspace/plasma-workspace-6.0.3/klipper/clipboardengine.cpp:39
#37 ClipboardEngine::~ClipboardEngine (this=0x6403b322dea0, this=<optimized out>) at /usr/src/debug/plasma-workspace/plasma-workspace-6.0.3/klipper/clipboardengine.cpp:39
#38 0x00007121dcc35740 in Plasma5Support::DataEngineManagerPrivate::~DataEngineManagerPrivate (this=0x6403b2959960, this=<optimized out>) at /usr/src/debug/plasma5support/plasma5support-6.0.3/src/plasma5support/private/dataenginemanager.cpp:48
#39 Plasma5Support::DataEngineManager::~DataEngineManager (this=0x7121dcc49ab0 <_ZZN13QGlobalStaticIN14QtGlobalStatic6HolderIN14Plasma5Support12_GLOBAL__N_134Q_QGS_privateDataEngineManagerSelfEEEE8instanceEvE6holder.lto_priv.0>, this=<optimized out>) at /usr/src/debug/plasma5support/plasma5support-6.0.3/src/plasma5support/private/dataenginemanager.cpp:88
#40 0x00007121dcc35a4d in Plasma5Support::DataEngineManagerSingleton::~DataEngineManagerSingleton (this=<optimized out>, this=<optimized out>) at /usr/src/debug/plasma5support/plasma5support-6.0.3/src/plasma5support/private/dataenginemanager.cpp:67
#41 QtGlobalStatic::Holder<Plasma5Support::(anonymous namespace)::Q_QGS_privateDataEngineManagerSelf>::~Holder (this=<optimized out>, this=<optimized out>) at /usr/include/qt6/QtCore/qglobalstatic.h:43
#42 0x00007121e565cb36 in __run_exit_handlers (status=status@entry=1, listp=0x7121e57f6680 <__exit_funcs>, run_list_atexit=run_list_atexit@entry=true, run_dtors=run_dtors@entry=true) at exit.c:108
#43 0x00007121e565cc80 in __GI_exit (status=status@entry=1) at exit.c:138
#44 0x00007121e0db67d1 in QXcbConnection::processXcbEvents (this=0x6403b15e3300, flags=...) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/plugins/platforms/xcb/qxcbconnection.cpp:1071
#45 0x00007121e0ddebb7 in xcbSourceDispatch (source=<optimized out>) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/plugins/platforms/xcb/qxcbeventdispatcher.cpp:55
#46 0x00007121e49d4199 in g_main_dispatch (context=0x7121d8000f00) at ../glib/glib/gmain.c:3344
#47 0x00007121e4a333bf in g_main_context_dispatch_unlocked (context=0x7121d8000f00) at ../glib/glib/gmain.c:4152
#48 g_main_context_iterate_unlocked.isra.0 (context=context@entry=0x7121d8000f00, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:4217
#49 0x00007121e49d3712 in g_main_context_iteration (context=0x7121d8000f00, may_block=1) at ../glib/glib/gmain.c:4282
#50 0x00007121e5f73cd4 in QEventDispatcherGlib::processEvents (this=0x6403b1622590, flags=...) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qeventdispatcher_glib.cpp:393
#51 0x00007121e5d446ee in QEventLoop::processEvents (flags=..., this=0x7ffdd0a59560) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qeventloop.cpp:100
#52 QEventLoop::exec (this=0x7ffdd0a59560, flags=...) at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/kernel/qeventloop.cpp:182
#53 0x00007121e5d3cc38 in QCoreApplication::exec () at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/corelib/global/qflags.h:74
#54 0x00007121e7af0efa in QApplication::exec () at /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.3/src/widgets/kernel/qapplication.cpp:2574
#55 0x00006403afe5a476 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/plasma-workspace/plasma-workspace-6.0.3/shell/main.cpp:214
Comment 3 Bug Janitor Service 2024-04-23 18:19:50 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kglobalaccel/-/merge_requests/106
Comment 4 ratijas 2024-04-24 12:32:30 UTC
Git commit 8e8ef50b9faa3c2365dcf60f9d8dac71c55c0440 by ivan tkachenko.
Committed on 23/04/2024 at 18:18.
Pushed by ratijas into branch 'master'.

Fix connection lifetime issue

The lack of receiver may cause undefined behavior / segmentation fault
crash if, for example, a KActionCollection is stored as a
Q_GLOBAL_STATIC too and coincidentally gets destructed after the
KGlobalAccel singleton instance.

Note that all other connections in this file use this `q->connect` style
and already have a context object set to `q`.

Test case: Run `plasmoidviewer -a org.kde.plasma.clipboard`. With this
patch is still crashes on exit, but now in a different place.
Related: bug 454854

M  +1    -1    src/kglobalaccel.cpp

https://invent.kde.org/frameworks/kglobalaccel/-/commit/8e8ef50b9faa3c2365dcf60f9d8dac71c55c0440
Comment 5 Nicolas Fella 2024-05-30 12:59:19 UTC
Potentially fixed by https://codereview.qt-project.org/c/qt/qtdeclarative/+/564387
Comment 6 Nate Graham 2024-08-22 19:11:35 UTC
*** Bug 492008 has been marked as a duplicate of this bug. ***
Comment 7 Nate Graham 2024-08-27 18:47:09 UTC
*** Bug 492185 has been marked as a duplicate of this bug. ***
Comment 8 TraceyC 2024-09-12 14:33:38 UTC
*** Bug 492809 has been marked as a duplicate of this bug. ***