Summary: | Konsole 20.04.0 crashes on start | ||
---|---|---|---|
Product: | [Applications] konsole | Reporter: | Michael Marley <michael> |
Component: | general | Assignee: | Konsole Developer <konsole-devel> |
Status: | RESOLVED WORKSFORME | ||
Severity: | crash | CC: | a.samirh78, michael, nate, rikmills |
Priority: | HI | Keywords: | drkonqi |
Version: | 20.04.0 | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Michael Marley
2020-04-30 19:08:28 UTC
It looks like the crash is probably related to https://github.com/KDE/konsole/commit/6db7f8d2593ccb0238b2b547ed6eaf7da6a26c4c. Ahmad, could you look at this? Looking at the backtrace, my guess would be it's crashing when trying to access the bookmarkAction pointer in: if (bookmarkAction->shortcut() == QKeySequence(Konsole::ACCEL + Qt::Key_B)) { collection->setDefaultShortcut(bookmarkAction, Konsole::ACCEL + Qt::SHIFT + Qt::Key_B); } which doesn't make sense. I tried to reproduce the issue in a vm, but couldn't install the updates from the ppa (I am not an ubuntu user, so I don't know the quirks to get stuff to install there). Also I couldn't find a konosle 20.04 in that ppa. (In reply to Ahmad Samir from comment #3) I tried to reproduce the issue in a vm, but > couldn't install the updates from the ppa (I am not an ubuntu user, so I > don't know the quirks to get stuff to install there). Also I couldn't find a > konosle 20.04 in that ppa. Wrong link to the PPA in the bug description. It should be... https://launchpad.net/~kubuntu-ppa/+archive/ubuntu/staging-kdeapplications I preface this by saying I've never run ubuntu before, so. It seems to me you're installing konsole 20.04 from groovy ppa, but kbookmarks-5.69 comes from "focal" ppa? is that supposed to work? Oops, right you are. I still had the Frameworks 5.69 from Focal installed from before I upgraded to Groovy. If I install 5.68 from Groovy, Konsole doesn't crash. I'm assuming if Konsole was actually built against 5.69, it would not crash. I don't see "REPORTER IS IDIOT" in the resolution reason list, so I am closing this as "NOT A BUG". Sorry for wasting everyone's time. Well, frameworks are supposed to be compatible. The only "allowed" crash is if you build Konsole against 5.69, but then run it against 5.68. If you build Konsole against 5.68, it must work with 5.68 and 5.69. FYI 5.69 was built for focal in the staging PPA, but not shipped as it was too late to get in. We thought it might be good for early backports, but Nate suggested skipping 5.69 to wait for 5.70 for groovy and focal backports, as 5.69 had some bugs that would need a fair amount a patch cherry=picking from 5.70. So 5.69 is siting there in a PPA for focal, but is not going anywhere. Testers who added that to focal and who are now on groovy, are in a slightly odd situation right now. The packages in the KDE applications PPA (konsole 20.04.0 etc) where built against the 5.68 currently in groovy. @Michael: lucky you, there's actually a bug to be fixed here, so thanks for reporting it. (I've reported many a bug that turned out to be absolutely useless :)). The issue here is that kbookmarks-5.69 didn't create a KActionCollection, this was fixed in 5.70 https://cgit.kde.org/kbookmarks.git/commit/?id=4b3fc2aedd86505a47b9b185e086ef253e73ede8 We can fix it in konsole by simply checking the action actually exists before hijacking it, I'll submit a patch for review. Thinking about this some more, I think the proper fix is to patch kbookmarks-5.69 with https://cgit.kde.org/kbookmarks.git/commit/?id=4b3fc2aedd86505a47b9b185e086ef253e73ede8 ; IIUC, Rik Mills can handle the PPA. I've also sent an email to the distributions@kde.org ML to notify packagers of the issue. Also note that KF 5.70 is about to be released anyway. Rik just put KF5 5.70 in the -staging PPA, but Konsole is still crashing on start for me. Yes, Konsole 19.12.3 does not crash with Frameworks 5.70. Konsole 20.04.0 DOES crash. - Konsole 20.04.0 in Ubuntu 20.10 archive built against 5.68 in the Ubuntu 20.04 Groovy archive, does not crash. - The same Konsole 20.04.0 in Ubuntu 20.10 archive DOES crash when frameworks is upgraded to 5.70 form this PPA: https://launchpad.net/~kubuntu-ppa/+archive/ubuntu/staging-frameworks?field.series_filter=groovy - Konsole 20.04.0 then rebuilt against 5.70 in that PPA does NOT crash. Hence with this current situation, when I upgrade frameworks in Groovy from 5.68 to 5.70 next week (we are skipping 5.69) then I will need to rebuild Konsole to avoid it crashing on start. This is not an ideal or satisfactory thing to have to do on a frameworks upgrade, as binary compatibility should not be broken. Konsole 20.04 built against 5.68 will have selected the path in the code that depends on KBookmarks creating a KActionCollection. KBookmarks-5.70 does create an action collection, so konsole should work without rebuilding AFAICT. Unless 5.70 was built with disabling deprecated KF API, in which case the KBookmarksMenu ctor that takes a KActionCollection isn't available at all. @Christoph: if some API was deprecated, then Konsole would need a rebuild, right? If deprecated API was disabled, but still used, it should indeed have caused a compilation error. If it's not disabled, deprecated API needs to work as long as it isn't removed in the next ABI incompatible version. If it cannot be made to work, at least it shouldn't cause crashes. Discussing the issue with kossebau on IRC, I was completely wrong about the deprecation stuff, so please disregard. He investigated the issue further and found the critter causing it: https://phabricator.kde.org/D28800#663274 Will definitely get fixed before KF 5.70 is out. Proposed fix https://phabricator.kde.org/D29427 Git commit 8a282319bc9eb6dd73557319cbd59d279493cdab by Ahmad Samir. Committed on 04/05/2020 at 21:59. Pushed by ahmadsamir into branch 'master'. [KBookmarkMenu] Assign m_actionCollection early to prevent crash Summary: The deprecated ctor that took a KActionCollection param called the new ctor (that doesn't take an actionCollection before) m_actionCollection was assigned. This caused the menu actions never to get added to the actionCollection as it was still nullptr. This caused crashes in applications that still use the deprecated ctor, e.g. this bug in konsole https://bugs.kde.org/show_bug.cgi?id=420820. Since we can't assign m_actionCollection in the initializer list because then the constructor delegation would follow a member initializer (info courtsey of the compiler), introduce a helper init method to reduce code duplication between the two ctor's. Thanks to Friedrich W. H. Kossebau for figuring it out https://phabricator.kde.org/D28800#663274. Test Plan: make && ctest Reviewers: #frameworks, dfaure, kossebau, nicolasfella Reviewed By: dfaure Subscribers: rikmills, kde-frameworks-devel Tags: #frameworks Differential Revision: https://phabricator.kde.org/D29427 M +14 -3 src/kbookmarkmenu.cpp M +2 -0 src/kbookmarkmenu.h https://commits.kde.org/kbookmarks/8a282319bc9eb6dd73557319cbd59d279493cdab I tested in an ubuntu vm, and it seems to work. Closing as worksforme, as the fix isn't within konsole but rather kbookmarks. Feel free to reopen if you disagree. |