Page MenuHomePhabricator

Search for phrase queries does not highlight page content
Closed, ResolvedPublic

Description

When searching using quoted queries "foo bar" MW 1.27 does not show the text snippet, only page titles are shown. This seems to be a regression since MW 1.23 appeared to display text snippets properly.

Event Timeline

dcausse created this task.Jun 13 2017, 1:36 PM
Restricted Application added projects: Discovery, Discovery-Search. · View Herald TranscriptJun 13 2017, 1:36 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
debt triaged this task as Normal priority.Jun 15 2017, 5:09 PM
debt edited projects, added Discovery-Search (Current work); removed Discovery-Search.
debt added a subscriber: debt.

Possibly related (regression) to T167800.

Kghbln added a subscriber: Kghbln.Jun 15 2017, 6:22 PM
Kghbln added a comment.EditedJun 15 2017, 6:33 PM

For the sake of completeness:

Setup

  • MediaWiki core without additional search extensions
  • PHP 5.6.30 (cgi-fcgi)
  • MySQL 5.1.73-log, however this was also observed on 5.5.55-0+deb8u1

Search result on 1.23.15
Search string "September 2010"

Search result on 1.25.6
Search string "September 2010" - text snippets are gone

Search result on 1.27.3
Search string "September 2010"

So the regression was either introduced with REL1_24 or REL_125 since 1.25.6 already does not longer show the text snippets. The user can no longer assess the relevancy for looking at the snippet. Also the different occurrences of the search string on the pages is not visible.

The number of results is the expected number of results and their ranking within the results shown is identical in all versions.

Since I only move from LTS release to LTS release it is now that I realized the issue.

Change 360843 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@master] Fix highlighting for phrase queries

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

dcausse claimed this task.Jun 22 2017, 1:07 PM
dcausse moved this task from in progress to Needs review on the Discovery-Search (Current work) board.

Change 360843 merged by jenkins-bot:
[mediawiki/core@master] Fix highlighting for phrase queries

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

Change 361832 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@REL1_27] Fix highlighting for phrase queries

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

Change 361833 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@REL1_28] Fix highlighting for phrase queries

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

Change 361834 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@REL1_29] Fix highlighting for phrase queries

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

Change 361833 merged by jenkins-bot:
[mediawiki/core@REL1_28] Fix highlighting for phrase queries

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

Change 361834 merged by jenkins-bot:
[mediawiki/core@REL1_29] Fix highlighting for phrase queries

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

Change 361832 merged by jenkins-bot:
[mediawiki/core@REL1_27] Fix highlighting for phrase queries

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

@dcausse Thanks a lot. Great work. The text snippets are back again!

One thing is however changed now. Searching for "September 2010" and September 2010 now return identical results, i.e. there is no difference between using them. On 1.23 searching for "September 2010" actually returned matches for "September 2010" as opposed to just returning matches for "September" as it happens when using September 2010. Since the results are now identical better search results using "September 2010" over September 2010 seems no longer to be possible. Is this something that should be discussed at T167800?

@Kghbln indeed you're right... I broke something, currently looking into solutions. I'll upload a new patch probably tomorrow.

Change 362154 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@master] Fix phrase search

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

Change 362154 merged by jenkins-bot:
[mediawiki/core@master] Fix phrase search

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

Change 363571 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@REL1_27] Fix phrase search

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

Change 363572 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@REL1_28] Fix phrase search

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

Change 363573 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/core@REL1_29] Fix phrase search

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

Change 363573 merged by jenkins-bot:
[mediawiki/core@REL1_29] Fix phrase search

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

Change 363571 merged by jenkins-bot:
[mediawiki/core@REL1_27] Fix phrase search

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

Change 363572 merged by jenkins-bot:
[mediawiki/core@REL1_28] Fix phrase search

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

Kghbln closed this task as Resolved.Jul 7 2017, 7:53 AM

@dcausse I have just done a field test on REL1_27 master and can confirm that the search is showing the expected behavior again and the testing scenario works perfect. That's great news! Thanks you so much for your effort and help. Very much appreciated indeed! Have a nice weekend. You deserve it! :)

debt awarded a token.Jul 7 2017, 11:36 PM
Kghbln awarded a token.Jul 8 2017, 9:32 AM