Bug 363630 - Crash: Spectacle hangs when using save as on a desktop where the default file dialog it gtk's
Summary: Crash: Spectacle hangs when using save as on a desktop where the default file...
Status: RESOLVED FIXED
Alias: None
Product: Spectacle
Classification: Applications
Component: General (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Boudhayan Gupta
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-05-28 14:51 UTC by Halla Rempt
Modified: 2019-07-21 20:56 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Halla Rempt 2016-05-28 14:51:33 UTC
This probably is caused by the GTK file dialog the Qt clipboard fighting. We solved the issue in Krita by blocking the QClipboard signals before opening the file dialog. See 

https://phabricator.kde.org/diffusion/KRITA/browse/master/libs/widgetutils/KoFileDialog.cpp
Comment 1 Peter Wu 2016-10-12 09:32:02 UTC
Do you have a gdb backtrace?

Can you point to the exact commit that fixed this for Krita? I see a bunch of changes at https://phabricator.kde.org/diffusion/KRITA/history/master/libs/widgetutils/KoFileDialog.cpp

Finally Krita removed the native dialog in https://phabricator.kde.org/rKRITAcfc4efaf01cc17e795dfcac972563d4095cbd02f in attempt to solve bug 364864 (which it did not according to the comments?)
Comment 2 Halla Rempt 2016-10-13 08:47:19 UTC
Er... No, it's so long ago that I don't have a backtrace anymore. The relevant commit is:L

commit a73c6840854a4fae24019a88ebcfd89dad250d71
Author: Boudewijn Rempt <boud@valdyas.org>, Wed Aug 6 16:57:49 2014 +0200 (2 years, 2 months ago)
Committer: Boudewijn Rempt <boud@valdyas.org>, Wed Aug 6 16:57:49 2014 +0200 (2 years, 2 months ago)
Precedes: v2.99.88
Branches: <Expand>

BUG:338067 Workaround broken cliplboard in the the gtk file dialog

Krita hangs when it gets a signal from the application clipboard when
the user copies a string in the gtk-based file dialog. This hangs
somewhere deep in Qt, with a seemlingly endless loop in

QVariant QMimeDataPrivate::retrieveTypedData(const QString &format, QVariant::Type type) const

By blocking the clipboard's signals we avoid the hang.
Comment 3 Peter Wu 2016-10-14 09:38:37 UTC
Is this issue still reproducible or can the bug be closed?
Comment 4 Halla Rempt 2016-10-14 09:49:50 UTC
It is reproducible with 15.12.3; I tried to update yesterday but apparently opensuse leap doesn't have a newer version yet.
Comment 5 Peter Wu 2016-10-14 09:56:47 UTC
If it is reproducible, can you attach a gdb backtrace? Thanks :)
Comment 6 Boudhayan Gupta 2019-06-12 08:58:03 UTC
Updated versions of KDE software probably doesn't make a difference here; you'll need the latest version of Gtk.

Is there some way to force using Gtk's QPA plugin when launching Spectacle? I could test it on Arch, maybe.
Comment 7 Peter Wu 2019-07-21 11:42:38 UTC
(In reply to Boudhayan Gupta from comment #6)

> Is there some way to force using Gtk's QPA plugin when launching Spectacle?
> I could test it on Arch, maybe.

You can force it with:
QT_QPA_PLATFORMTHEME=gtk3 spectacle

However on Arch I cannot reproduce a crash on saving the screenshot:
spectacle 19.04.2-1
gtk3 1:3.24.10-1
qt5-base 5.13.0-7
Comment 8 Nate Graham 2019-07-21 20:56:40 UTC
Me neither. Let's re-open if we see it again.