Topic: [Bug?] Wiki search queries return somewhat unintuitive results

Posted under Site Bug Reports & Feature Requests

Bug overview description.
The way wiki search results are displayed may come across as unintuitive for some

What part(s) of the site page(s) are affected?

Wiki: Wiki search page

What is the expected behavior?

??

What actual behavior is given instead?

There are 2 major apparent issues:

1. Whitespace seems to be parsed as an underscore for match displaying

eg1. on top

returns 0 results

but on_top returns >0 results

2. Results don't list exact matches first

eg2. penis

Gives 4 results before the 'penis' article
-
This is probably because the default order for search results are by Date
TMK, there's no way to do literal searches

'penis'

and "penis" both return nothing

Time of incident (if applicable).

N/A: consistently reproducible [this has been happening for months now, iirc]

Can you reproduce the bug every time?
Yes

What steps did you take to replicate this bug?
1. Search the wiki for any tag/article which includes whitespace/underscores

2. Search the wiki for any base tag with variants in the name

Errors or other messages returned (if any).
N/A

Updated by Genjar

Since wiki pages are roughly an extension of the tag system, they obey tag naming rules. Underscores are converted to spaces upon display. I'm not sure if the search option allowing spaces even makes sense, since you can't search for more than one title at a time.

Converting spaces to underscores for the purpose of searching would make more sense from my initial investigation.

Updated by anonymous

To address the second issue, I think I can calculate the distance between the input and the actual name and use that to determine a better sorting order. Something to look into.

Updated by anonymous

Yay!

There could be a checkbox or something for the first one, maybe?:

[] Treat underscores as whitespace

(maybe something more member-friendly

-

And the second one too, I guess:

[] Exact match

Updated by anonymous

Genjar

Former Staff

I think it'd be best to keep it like it is, to teach users that they need to use underscores.

Since those are required for tagging and regular searches. Why should the wiki be different?

Updated by anonymous

It would be nice acclimatization,yeah

I think it's probably more frustrating than enlightening when you're just trying to find an article and have to type out a bunch of underscores each time though
-
A search for 'body types' returns nothing
if you're looking for the tag group:body types wiki

-
Which (the article title) is none of the following:

  • a tag
  • visibly-underscored

Updated by anonymous

Genjar

Former Staff

Maybe the wiki search should ignore everything except the first word. Then if someone tries to search for something like 'body types', they'd get results for 'body' instead. Which, while broader, would still find it.

Updated by anonymous

  • 1