Skip to content
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

[COSMIC Epoch; regression] Search results don't show apps when too many windows are open #228

Closed
jacobgkau opened this issue Jul 17, 2024 · 4 comments · Fixed by #229
Closed

Comments

@jacobgkau
Copy link
Member

This seems to be caused by 1725320. It does not happen on ab7a71a. (FYI, @wiiznokes in case you have an idea of why this might be happening.)

Previously, search results would return application names even if a lot of windows are open:

screenshot-2024-07-17-14-20-20

On the latest commit, searching for the same string, I'm getting a bunch of irrelevant (but presumably closest-matching) window results, and no application results:

screenshot-2024-07-17-14-21-46

This essentially breaks launching apps with the launcher once more than 8 windows are open.

The good news is, this is not happening in the GNOME session (which is why I didn't catch it during regression testing).

@mmstick
Copy link
Member

mmstick commented Jul 17, 2024

It's a difference in behavior between the cosmic and pop-shell launcher plugins.

@wiiznokes
Copy link
Contributor

This is because the new commit match more field of the desktop entries. In this case, it will match the "internet" categorie of firefox.

Somehow, strsim::jaro_winkler("terminal", "internet"); return a score of 0.66, which is a lot. The plugin accept match > 0.6.

I'm not sure the best way of fixing this. This is kinda related to pop-os/cosmic-launcher#145. Maybe is would make sense to use different matching algorithm for different field. Like using a substring algo for Categories.

@wash2
Copy link
Contributor

wash2 commented Jul 18, 2024

Maybe is would make sense to use different matching algorithm for different field. Like using a substring algo for Categories.

Ya, I think that could work. Alternatively, requiring a higher score like 0.8 for matching the desktop entry, and a lower score like 0.6 for matching title and app id in the toplevel plugin seems to work pretty well too.

@wiiznokes
Copy link
Contributor

Maybe is would make sense to use different matching algorithm for different field. Like using a substring algo for Categories.

Ya, I think that could work. Alternatively, requiring a higher score like 0.8 for matching the desktop entry, and a lower score like 0.6 for matching title and app id in the toplevel plugin seems to work pretty well too.

pop-os/freedesktop-desktop-entry#22 does smtg like this

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.

4 participants