Bug 490147 - crash amarok 3
Summary: crash amarok 3
Status: RESOLVED FIXED
Alias: None
Product: amarok
Classification: Applications
Component: general (other bugs)
Version First Reported In: 3.0.1
Platform: Other Linux
: NOR crash
Target Milestone: kf5
Assignee: Amarok Bugs
URL:
Keywords: drkonqi
Depends on:
Blocks:
 
Reported: 2024-07-12 06:29 UTC by fabien beaufils
Modified: 2024-07-15 18:48 UTC (History)
1 user (show)

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


Attachments
attachment-2018949-0.html (2.35 KB, text/html)
2024-07-15 14:51 UTC, fabien beaufils
Details

Note You need to log in before you can comment on or make changes to this bug.
Description fabien beaufils 2024-07-12 06:29:12 UTC
Application: amarok (3.0.1)

Qt Version: 5.15.12
Frameworks Version: 5.115.0
Operating System: Linux 6.4.0-150600.23.7-default x86_64
Windowing System: X11
Distribution: "openSUSE Leap 15.6"
DrKonqi: 5.27.11 [KCrashBackend]

-- Information about the crash:
en mettant a jour les pochettes manquante  le logiciel c'est arreté

The crash can be reproduced sometimes.

-- Backtrace:
Application: Amarok (amarok), signal: Segmentation fault

[KCrash Handler]
#4  0x00007f8a8448c110 in QTextDocument::docHandle() const () from /usr/lib64/libQt5Gui.so.5
#5  0x00007f8a84483f38 in QTextFrame::begin() const () from /usr/lib64/libQt5Gui.so.5
#6  0x00007f8a844c5b4e in ?? () from /usr/lib64/libQt5Gui.so.5
#7  0x00007f8a844c6180 in ?? () from /usr/lib64/libQt5Gui.so.5
#8  0x00007f8a844c63b8 in QTextDocumentLayout::doLayout(int, int, int) () from /usr/lib64/libQt5Gui.so.5
#9  0x00007f8a844c6d0b in QTextDocumentLayout::documentChanged(int, int, int) () from /usr/lib64/libQt5Gui.so.5
#10 0x00007f8a844a0a9d in QTextDocumentPrivate::clear() () from /usr/lib64/libQt5Gui.so.5
#11 0x00007f8a8448ca76 in QTextDocument::setHtml(QString const&) () from /usr/lib64/libQt5Gui.so.5
#12 0x00007f8a84cd5af0 in ?? () from /usr/lib64/libQt5Widgets.so.5
#13 0x00007f8a84cd6d65 in ?? () from /usr/lib64/libQt5Widgets.so.5
#14 0x00007f8a84cd7e00 in ?? () from /usr/lib64/libQt5Widgets.so.5
#15 0x00007f8a84cd8497 in QLabel::minimumSizeHint() const () from /usr/lib64/libQt5Widgets.so.5
#16 0x00007f8a84cd8553 in QLabel::sizeHint() const () from /usr/lib64/libQt5Widgets.so.5
#17 0x00007f8a81898475 in KSqueezedTextLabel::sizeHint() const () from /usr/lib64/libKF5WidgetsAddons.so.5
#18 0x00007f8a84bc1ce4 in QWidgetItemV2::updateCacheIfNecessary() const () from /usr/lib64/libQt5Widgets.so.5
#19 0x00007f8a84bc1fcd in QWidgetItemV2::maximumSize() const () from /usr/lib64/libQt5Widgets.so.5
#20 0x00007f8a84bb6292 in ?? () from /usr/lib64/libQt5Widgets.so.5
#21 0x00007f8a84bb70a8 in QBoxLayout::maximumSize() const () from /usr/lib64/libQt5Widgets.so.5
#22 0x00007f8a84bb6292 in ?? () from /usr/lib64/libQt5Widgets.so.5
#23 0x00007f8a84bb70a8 in QBoxLayout::maximumSize() const () from /usr/lib64/libQt5Widgets.so.5
#24 0x00007f8a84bb6292 in ?? () from /usr/lib64/libQt5Widgets.so.5
#25 0x00007f8a84bb7a30 in QBoxLayout::setGeometry(QRect const&) () from /usr/lib64/libQt5Widgets.so.5
#26 0x00007f8a84bbdc78 in QLayoutPrivate::doResize() () from /usr/lib64/libQt5Widgets.so.5
#27 0x00007f8a84bbece8 in QLayout::activate() () from /usr/lib64/libQt5Widgets.so.5
#28 0x00007f8a84b9f847 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQt5Widgets.so.5
#29 0x00007f8a84ba663f in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/libQt5Widgets.so.5
#30 0x00007f8a83ed7d53 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib64/libQt5Core.so.5
#31 0x00007f8a83eda771 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /usr/lib64/libQt5Core.so.5
#32 0x00007f8a83f3aad3 in ?? () from /usr/lib64/libQt5Core.so.5
#33 0x00007f8a7fc56fac in ?? () from /usr/lib64/libglib-2.0.so.0
#34 0x00007f8a7fc58bd0 in ?? () from /usr/lib64/libglib-2.0.so.0
#35 0x00007f8a7fc591cc in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#36 0x00007f8a83f3a17c in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQt5Core.so.5
#37 0x00007f8a83ed65ba in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQt5Core.so.5
#38 0x00007f8a83edfdf7 in QCoreApplication::exec() () from /usr/lib64/libQt5Core.so.5
#39 0x0000558a5a7d212c in ?? ()
#40 0x00007f8a83440eec in __libc_start_call_main () from /lib64/libc.so.6
#41 0x00007f8a83440fb5 in __libc_start_main_impl () from /lib64/libc.so.6
#42 0x0000558a5a7d25d1 in ?? ()
[Inferior 1 (process 5512) detached]

Reported using DrKonqi
Comment 1 Tuomas Nurmi 2024-07-12 08:40:04 UTC
Thank you for your report! I didn't manage to reproduce this yet, but I'll try harder a bit later.

How many albums / missing album covers are you fetching approximately?

If you can reproduce this, it might be useful to get console output from "amarok --debug" prior to crash, too.
Comment 2 fabien beaufils 2024-07-15 14:51:57 UTC
Created attachment 171678 [details]
attachment-2018949-0.html

Hello, I have just reproduced the spit.
This happens after scanning the missing covers.
When I choose one to put on a CD the software crashes.

amarok: END__: void CoverFetcher::slotResult(const QUrl&, const 
QByteArray&, const NetworkAccessManagerProxy::Error&) [Took: 0.005s]
amarok: [CoverFetcher] Finished successfully for album "Blessed & 
Possessed (Mediabook Ed.) CD II"
amarok: [MySqlStorage] Initialized thread, count == 6
QObject: Cannot create children for a parent that is in a different thread.
(Parent is KSqueezedTextLabel(0x5626903df440), parent's thread is 
QThread(0x56268e2784b0), current thread is QThread(0x7f34f8001040)
amarok: [MySqlStorage] Deinitialized thread, count == 5
QObject: Cannot create children for a parent that is in a different thread.
(Parent is QTextDocument(0x7f34f8015a90), parent's thread is 
QThread(0x7f34f8001040), current thread is QThread(0x56268e2784b0)
KCrash: Application 'amarok' crashing...
KCrash: Attempting to start /usr/lib/drkonqi

[1]+  Stoppé                 amarok --debug
fabien@localhost:~> Unable to find file for pid 11647 expected at 
"kcrash-metadata/11647.ini"
QSocketNotifier: Invalid socket 5 and type 'Read', disabling...
QSocketNotifier: Invalid socket 13 and type 'Read', disabling...
QSocketNotifier: Invalid socket 76 and type 'Read', disabling...
Unable to start Dr. Konqi
Re-raising signal for core dump handling.



Le 12/07/2024 à 10:40, Tuomas Nurmi a écrit :
> hank you for your report! I didn't manage to reproduce this yet, but I'll try
> harder a bit later.
>
> How many albums / missing album covers are you fetching approximately?
>
> If you can reproduce this, it might be useful to get console output from
> "amarok --debug" prior to crash, too.
Comment 3 Tuomas Nurmi 2024-07-15 15:33:10 UTC
Very good, thank you! I can reproduce with the exact steps:
Have an album with no cover. Open cover manager, click "Fetch missing covers". Wait for the album to get a cover. After that, click manually "Fetch Cover" for that album, and try to assign a different cover to that -> crash.

Should be easily fixable, let's see.
Comment 4 Tuomas Nurmi 2024-07-15 18:48:29 UTC
Okay, it was a bit more complicated than it first seemed, being actually related to multiple threads wanting to alter UI items, but I think I got it. (Was also reproducible by hovering mouse over one of the album items on background while "Fetch Cover" dialog was open, and then a cover was selected there and dialog closed.)
Comment 5 Tuomas Nurmi 2024-07-15 18:48:41 UTC
Git commit 9fe735ac03eb8e2adba341a673c19a0ec1a6c047 by Tuomas Nurmi.
Committed on 15/07/2024 at 18:32.
Pushed by nurmi into branch 'master'.

Avoid thread-related crashes in CoverManager

Do all m_statusLabel updating through signals/slots so threads don't get messed up
when both CoverManager status and network events and CoverView mouseover want to
change it.

M  +1    -0    ChangeLog
M  +1    -2    src/covermanager/CoverManager.cpp
M  +0    -1    src/covermanager/CoverManager.h

https://invent.kde.org/multimedia/amarok/-/commit/9fe735ac03eb8e2adba341a673c19a0ec1a6c047