Summary: | Crash in ViewerWindow::showInlineMessage() when stopping recording with Webm | ||
---|---|---|---|
Product: | [Applications] Spectacle | Reporter: | Nate Graham <nate> |
Component: | General | Assignee: | Noah Davis <noahadvs> |
Status: | RESOLVED DUPLICATE | ||
Severity: | crash | CC: | el, kde, kde |
Priority: | NOR | Keywords: | qt6 |
Version: | git-master | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | New crash information added by DrKonqi |
Description
Nate Graham
2023-09-15 14:38:55 UTC
I see this bug report is for 23.04.1. Do you have the same bug with git master? It was indeed with git master, sorry. Could you tell me exactly what you're doing and what settings related to saving videos you have? I am unable to reproduce the crash. >#5 0x00007fd936cdb5f4 in QQuickView::rootObject() const () at /lib64/libQt6Quick.so.6
This is typically a sign that QML failed to load, hence no root object.
This could mean a missing import on the user. In either case spectacle should report any QML errors to stderr and exit gracefully.
(In reply to David Edmundson from comment #4) > >#5 0x00007fd936cdb5f4 in QQuickView::rootObject() const () at /lib64/libQt6Quick.so.6 > > This is typically a sign that QML failed to load, hence no root object. > This could mean a missing import on the user. In either case spectacle > should report any QML errors to stderr and exit gracefully. That was one of my first thoughts, but I asked Nate to put a Q_ASSERT(rootObject() != nullptr) there and he said it didn't trigger. I should have read this: #7 0x000000000046429e in ViewerWindow::showSavedVideoMessage(QUrl const&) (this=0x0, messageArgument=...) at /home/nate/kde/src/spectacle/src/Gui/ViewerWindow.cpp:152 this=0 ViewerWindow is not instantiated. The lifespan is managed by something else and there's effectively a weakpointer for the singleton. connect(m_videoPlatform.get(), &VideoPlatform::recordingSaved, this, [this](const QString &path) { const QUrl url = QUrl::fromUserInput(path, {}, QUrl::AssumeLocalFile); ViewerWindow::instance()->showSavedVideoMessage(url); and several other places are not guarding ViewerWindow::instance(). It should be either guarded or we should figure the lifespan (In reply to David Edmundson from comment #6) > I should have read this: > > #7 0x000000000046429e in ViewerWindow::showSavedVideoMessage(QUrl const&) > (this=0x0, messageArgument=...) at > /home/nate/kde/src/spectacle/src/Gui/ViewerWindow.cpp:152 > > this=0 > > ViewerWindow is not instantiated. The lifespan is managed by something else > and there's effectively a weakpointer for the singleton. > > connect(m_videoPlatform.get(), &VideoPlatform::recordingSaved, this, > [this](const QString &path) { > const QUrl url = QUrl::fromUserInput(path, {}, > QUrl::AssumeLocalFile); > ViewerWindow::instance()->showSavedVideoMessage(url); > > and several other places are not guarding ViewerWindow::instance(). > > It should be either guarded or we should figure the lifespan What's really weird about this is that it should currently be impossible to activate this code in a situation where the ViewerWindow is null. You can currently only start and stop recording while a ViewerWindow is open. A possibly relevant merge request was started @ https://invent.kde.org/graphics/spectacle/-/merge_requests/279 Fixed with the commits in https://invent.kde.org/graphics/spectacle/-/merge_requests/283. *** This bug has been marked as a duplicate of bug 469336 *** Created attachment 168624 [details]
New crash information added by DrKonqi
spectacle (23.08.4) using Qt 5.15.12
I was clicking "finish recording", it was a recoding of a specific window and fairly short.
-- Backtrace (Reduced):
#4 0x00007f1a9710b0c0 in QQuickView::rootObject() const () at /lib64/libQt5Quick.so.5
#5 0x000056429ac886dd in ViewerWindow::showInlineMessage(QString const&, QMap<QString, QVariant> const&) (this=0x0, qmlFile=..., properties=...) at /usr/src/debug/spectacle-23.08.4/src/Gui/ViewerWindow.cpp:146
#6 0x000056429ac78985 in ViewerWindow::showSavedVideoMessage(QUrl const&) (messageArgument=..., this=0x0) at /usr/src/debug/spectacle-23.08.4/src/Gui/ViewerWindow.cpp:161
#7 operator() (path=<optimized out>, __closure=0x56429ca1f110) at /usr/src/debug/spectacle-23.08.4/src/SpectacleCore.cpp:233
#10 QtPrivate::QFunctorSlotObject<SpectacleCore::SpectacleCore(QObject*)::<lambda(const QString&)>, 1, QtPrivate::List<const QString&>, void>::impl(int, QtPrivate::QSlotObjectBase *, QObject *, void **, bool *) (which=<optimized out>, this_=0x56429ca1f100, r=<optimized out>, a=<optimized out>, ret=<optimized out>) at /usr/include/qt5/QtCore/qobjectdefs_impl.h:443
|