Page MenuHomePhabricator

Make it possible to bypass automatic redirection to exact matches in commons
Closed, ResolvedPublic

Description

ATM on commons if you search for something and a page exists with your search term as a title, you'll automatically be redirected to that page

What this means in practice is that, for common search terms, the user gets a curated gallery page instead of a search results page, and that gallery page only contains a fraction of the available files

Some examples:

Search term "pipistrellus pipistrellus"

Search term "barack obama"

Search term "wexford" (my home town)

Search term "fugazi"

Search term "michelangelo"

Search term "poodle"

Search term "everest"

Search term "forest"

Search term "train"

Search term "mausoleums in iran"

Search term "axe"

Search term "joker"

Details

Event Timeline

Cparle created this task.Oct 11 2019, 12:11 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 11 2019, 12:11 PM
Cparle updated the task description. (Show Details)Oct 11 2019, 12:12 PM
Cparle updated the task description. (Show Details)
Restricted Application added a project: Discovery-Search. · View Herald TranscriptOct 11 2019, 1:48 PM

Change 542437 had a related patch set uploaded (by Cparle; owner: Cparle):
[mediawiki/core@master] Allow bypass of redirection to exact/near search matches in config

https://gerrit.wikimedia.org/r/542437

Cparle updated the task description. (Show Details)Oct 14 2019, 10:28 AM
Cparle updated the task description. (Show Details)
Cparle updated the task description. (Show Details)Oct 14 2019, 10:31 AM
Cparle updated the task description. (Show Details)Oct 14 2019, 10:48 AM
Cparle updated the task description. (Show Details)
Cparle updated the task description. (Show Details)Oct 14 2019, 11:02 AM
Cparle updated the task description. (Show Details)
This comment was removed by EBernhardson.

Two options that we typically use:

  • Set the fulltext=1 parameter in the search request. This will disable the go functionality. This is the suggested programatic approach.
  • Prepend a tilde to the query, such as ~cat. The tilde cancels the go functionality and is stripped from the search. This is the suggested approach for individual users.

Are these the best options? Perhaps not, but it's what exists today. Would any of that work?

I missed that this is a global option with per user override. This is reasonable, but I'd be careful with evaluating if users really find the difference better, or if the functionality needs to be more targeted to go selecting undesirable list/gallery pages. In particularly we know that something like 80 % of search sessions to wikipedias are directly satisfied with autocomplete + go, never seeing a search results page. I don't know if that same analysis holds true to commonswiki, we've never looked too closely.

With wikipedias users are typically looking for a page, so it makes sense to redirect to an exact page match.

Non-power users of commonswiki are likely to be looking for a file, and instead of hitting the search engine they're getting some other user's guess of what they might want - it's like using DMOZ instead of google search.

Change 542437 merged by jenkins-bot:
[mediawiki/core@master] Search: Provide new preference to control redirects on search matches

https://gerrit.wikimedia.org/r/542437

Change 549835 had a related patch set uploaded (by Cparle; owner: Cparle):
[operations/mediawiki-config@master] Turn off redirect on exact search match for commons

https://gerrit.wikimedia.org/r/549835

Change 549835 merged by jenkins-bot:
[operations/mediawiki-config@master] Turn off redirect on exact search match for beta commons

https://gerrit.wikimedia.org/r/549835

Gehel closed this task as Resolved.Wed, Nov 13, 4:29 PM
Gehel claimed this task.

Change 553510 had a related patch set uploaded (by Cparle; owner: Cparle):
[operations/mediawiki-config@master] Turn off redirect on exact search match for commons

https://gerrit.wikimedia.org/r/553510

Change 554372 had a related patch set uploaded (by Jforrester; owner: Jforrester):
[operations/mediawiki-config@master] Turn off redirect on exact search match for Commons

https://gerrit.wikimedia.org/r/554372

Change 553510 merged by jenkins-bot:
[operations/mediawiki-config@master] Turn off redirect on exact search match for Test Commons

https://gerrit.wikimedia.org/r/553510

Mentioned in SAL (#wikimedia-operations) [2019-12-03T22:21:23Z] <jforrester@deploy1001> Synchronized wmf-config/InitialiseSettings.php: Set wmgDoNotRedirectOnSearchMatch, default off, on for Test Commons T235263 (duration: 01m 01s)

@Ramsey-WMF, your call as to when to deploy this to Commons; it's enabled on Test Commons as of a few seconds ago.

Mentioned in SAL (#wikimedia-operations) [2019-12-03T22:22:55Z] <jforrester@deploy1001> Synchronized wmf-config/CommonSettings.php: Read wmgDoNotRedirectOnSearchMatch to decide to enable auto-redirect search result change T235263 (duration: 01m 00s)

@Jdforrester-WMF we're good to go anytime. Thanks!

Change 554372 merged by jenkins-bot:
[operations/mediawiki-config@master] Turn off redirect on exact search match for Commons

https://gerrit.wikimedia.org/r/554372

Mentioned in SAL (#wikimedia-operations) [2019-12-05T23:44:57Z] <jforrester@deploy1001> Synchronized wmf-config/InitialiseSettings.php: T235263 Turn off redirect on exact search match for Commons (duration: 01m 00s)

OK, this is now deployed.

Weird. Works fine on test-commons afaics. I also don't get the expected preference on production commons, and I do on test commons. I can't see anything wrong with the config code. @Jdforrester-WMF any thoughts?

No. :-( I'll poke it a bit more.

Oh, I'm an idiot. The code for this landed in wmf.8 is which on Test Commons but not Real Commons yet.

Cparle added a comment.Mon, Dec 9, 5:03 PM

Ah! Phew! So nothing amiss, we just need to wait until ... Thursday?

Real Commons is now running wmf.8 as of ~3 minutes ago, so this is now live.

Raymond added a subscriber: Raymond.Mon, Dec 9, 5:42 PM