Bug 400250 - alt-f2 too quickly launching wrong desktop file
Summary: alt-f2 too quickly launching wrong desktop file
Status: RESOLVED FIXED
Alias: None
Product: krunner
Classification: Plasma
Component: general (show other bugs)
Version: 5.18.0
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: David Edmundson
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-24 15:15 UTC by Ludwig Nussel
Modified: 2023-04-27 21:55 UTC (History)
5 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ludwig Nussel 2018-10-24 15:15:05 UTC
SUMMARY

I changed the command line of the xterm desktop file via editing the entry in the menu to have a different font size and color. Ie there is now a copy of the desktop file in my home (~/.local/share/applications/xterm.desktop). Now if I type "alt-f2 xterm enter" it more often than not launches the unmodified desktop file.

SOFTWARE VERSIONS
(available in About System)
KDE Plasma Version: 5.12.6
KDE Frameworks Version: 5.45.0
Qt Version: 5.9.4

ADDITIONAL INFORMATION
openSUSE Leap 15.0
https://bugzilla.opensuse.org/show_bug.cgi?id=1107255
Comment 1 David Edmundson 2018-10-24 15:46:55 UTC
>type "alt-f2 xterm enter" it more often than not launches the unmodified desktop file.

Can you change the visible name in your local version and see what krunner is showing. Do you see both entries or just one.

Also please run kbuildsycoca5 to regenerate the apps DB.
Comment 2 Ludwig Nussel 2018-10-25 11:28:02 UTC
Aha, so I added "-bg yellow" to /usr/share/applications/xterm.desktop to be able to differentiate between a white, yellow and bigger font xterm. Turns out that actually when typing too fast alt-f2 just executes plain xterm itself as command. Ie I get a white xterm. If I'm a bit slower the one from my home with bigger font is launched.

Then I changed then name of my local copy to 00XTerm. Now the command line choice ends up always on top so I always get a white xterm. There is no duplicate desktop file entry. However, the desktop file entry never goes back to the top now. Even after deleting ~/.local/share/applications/xterm.desktop, running kbuildsycoca5, rebooting *sigh*.
Comment 3 Ludwig Nussel 2018-10-25 11:31:10 UTC
ok, found the settings button and turned off all modules besides applications. Not exactly what that thing was intended for I guess but at least reliable now :-)
Comment 4 Justin Zobel 2020-11-08 11:11:44 UTC
I can confirm this too. I'd like to see this turned into a feature request (wishlist item).

It would be great if krunner had a priority system. Which plugin should be matched first if a text entry matches multiple.

ie I can type konsole and it will give me multiple options but the Application isn't at the top (default selection).

What are others thoughts on this?
Comment 5 Nate Graham 2023-04-27 21:55:32 UTC
KRunner has been changed over the years to prefer apps over local files in such situations. Should be fixed now as of Plasma 5.27. If it's not, please feel free to re-open the bug report.