elementary / appcenter

Pay-what-you-can app store for elementary OS
https://elementary.io
GNU General Public License v3.0
542 stars 101 forks source link

Multi-word search treated as OR instead of AND #1512

Open cassidyjames opened 3 years ago

cassidyjames commented 3 years ago

What Happened

If I search for a multi-word query, it appears to be searching as an OR query; for example, if I search for gnome game, I get all results that match gnome OR game.

Expected Behavior

I would expect a more precise search term to narrow down results, not broaden them. At the very least, we should re-order results based on the presence of both terms, but it seems like the initial query is broken in the first place.

Steps to Reproduce

  1. Open AppCenter
  2. Search for a multi-word string, e.g. gnome game
  3. See the results

Platform Information

elementary OS 6 early access with AppCenter from master

tintou commented 3 years ago

I think that it should be both but prioritized by number of terms match

davidmhewitt commented 3 years ago

This sounds mostly like a request for AppStream, as AppCenter is not deciding which applications get returned for a given search query, just sorting them.

However, if we backport a newer release of AppStream first, we can try removing our manual sorting of the results and use AppStream's as I've fixed a bug with it and exposed some more information that would make the sorting easier.