Skip to content

Improve program name launcher sort order #1087

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
nathansgithub opened this issue Jul 15, 2021 · 3 comments · Fixed by #1139
Closed

Improve program name launcher sort order #1087

nathansgithub opened this issue Jul 15, 2021 · 3 comments · Fixed by #1139

Comments

@nathansgithub
Copy link

nathansgithub commented Jul 15, 2021

This is a minor thing, but it would improve usability.

(1) Issue/Bug Description:
Launcher program search should prioritize matching first part of word.

(2) Steps to reproduce (if you know):
Install Steam and install the Microsoft Teams flatpak from Pop Shop. Bring up the launcher and type 'team'. Steam shows up before Microsoft Teams.
image

(3) Expected behavior:
Both of these should show up, but Microsoft Teams should show up first in the search. It is more likely that users will search for an app by typing one of the words in the name than typing out the middle part of one of the words.

(4) Distribution (run cat /etc/os-release):
NAME="Pop!_OS"
VERSION="21.04"
ID=pop
ID_LIKE="ubuntu debian"
PRETTY_NAME="Pop!_OS 21.04"
VERSION_ID="21.04"
HOME_URL="https://pop.system76.com"
SUPPORT_URL="https://support.system76.com"
BUG_REPORT_URL="https://github.com/pop-os/pop/issues"
PRIVACY_POLICY_URL="https://system76.com/privacy"
VERSION_CODENAME=hirsute
UBUNTU_CODENAME=hirsute
LOGO=distributor-logo-pop-os

(5) Gnome Shell version:
3.38.5

(6) Pop Shell version (run apt policy pop-shell or provide the latest commit if building locally):

  Installed: 1.1.0~1626203716~21.04~021c931
  Candidate: 1.1.0~1626357201~21.04~c1f2ea4
  Version table:
     1.1.0~1626357201~21.04~c1f2ea4 1001
       1001 http://ppa.launchpad.net/system76/pop/ubuntu hirsute/main amd64 Packages
       1001 http://ppa.launchpad.net/system76/pop/ubuntu hirsute/main i386 Packages
 *** 1.1.0~1626203716~21.04~021c931 100
        100 /var/lib/dpkg/status
@nathansgithub
Copy link
Author

nathansgithub commented Jul 15, 2021

I checked and the default Gnome app search doesn't bring up programs if you type a sequence in the middle of a word: Searching 'team' only brings up Microsoft Teams and not Steam.

If that is less complicated than showing both and changing the sort order, I think that's a better behavior. If I'm trying to open Steam, I won't try searching for 'team'.

@nathansgithub nathansgithub changed the title Improve program name search sort order Improve program name launcher sort order Jul 15, 2021
@jacobgkau
Copy link
Member

Thank you for pointing out this scenario. I think search algorithm improvements are currently waiting on some work to move searching from the extension's JavaScript process into a separate Rust component, as the last few search improvements caused noticeable speed reductions in JavaScript. Once that's been done, prioritizing matches that follow a space over matches that follow any other character shouldn't be too difficult.

@jacobgkau
Copy link
Member

This is going to be fixed by #1139, since pop-os/launcher@b5514a6 changed the sort algorithm from Levenshtein distance to Jaro-Winkler distance, with Jaro-Winkler including a prefix weight for up to four characters. With Microsoft Teams and Steam both installed, searching team, tea, or teams now displays Microsoft Teams as the first result instead of Steam.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants