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
Run exact match search by default but add button to extend it #126
Conversation
This is the pattern adjust to be '*pattern*' as necessary.
Search one: - pattern Extend: - pattern* Extend: - *pattern*
Fixes #43 |
If you know that there is more than one result, then we have already done the search. I don't understand why we don't just include those results in the first page instead of asking the user to do a second operation and click 'Extend'. |
I can't think of another UI that has a search field that returns only exact matches by default, but then requires you to click an extend button to resubmit the search... to actually search. I had a proposal in IRC to implement this by: making two subsequent queries -- one for exact matches, and one by a pattern -- and to return those two lists concatenated together as the results. It covers all use cases I can think of with simpler interactions on the user's part. Is there something wrong with this approach? |
Search for |
Well it does not solve the original question from @glensc on #43. It makes it easier to get the results but not able to do exact match. |
He didn't say that he wanted to be redirect directly to what he wanted. He only said that he
It does solve the problem because it puts the exact match first in the list where it is obvious and easy to click on. If a user searches for 'nethack', then the nethack package ought show up first.. but it seems incorrect to me to ask the user to click an Extend button to also get the 'nethack-vultures' package to show up. If they knew very precisely that they wanted to go directly to the 'nethack' package, they could have just typed it into the URL and not bothered searching to begin with. Furthermore, the logic as currently implemented in this changeset where " If there is only one result, the user will be redirected to its page." makes it odd for novice users to search for all things with "ruby". They'll go to search and type 'ruby' and then be redirected away from the search interface and over to the project for the ruby core project. They'll have to know about the extended syntax.. go back to the search interface and type it again with "ruby". If I go to most any other search interface out there on the internet (google, fedora-packages, etc..) and type 'ruby' I don't get back things that only exactly match 'ruby'. I get first things that exactly match 'ruby' but then also things later in the results that have the string 'ruby' in them somewhere (i.e., rubygems-this and rubygems-that). The approach as implemented here exposes implementation details about the underlying database to the user and asks them to adapt their behavior to that layer, instead of providing a search interface that is more familiar and has more in common with most other search interfaces. |
Step one: - Exact match search for pattern - Generic search for *pattern*
👍 Thanks Pierre! |
Thanks @ralphbean |
Run exact match search by default but add button to extend it
By default anitya will now do exact match searches on project and package name.
If there is only one result, the user will be redirected to its page.
If there are more than one result, the user will be presented with a button entitled
Extend
offering the possibility to extend the search.