Last modified: 2013-06-18 15:50:59 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T19113, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 17113 - MWSuggest ignores some page titles
MWSuggest ignores some page titles
Status: RESOLVED WORKSFORME
Product: MediaWiki
Classification: Unclassified
Search (Other open bugs)
unspecified
All All
: Low normal with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2009-01-21 22:29 UTC by Purodha Blissenbach
Modified: 2013-06-18 15:50 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Purodha Blissenbach 2009-01-21 22:29:02 UTC
In Wikimedia Commons, when you type a single "0" (zero) in the
search field, you are shown 2 page titles. There are indeed only
two pages, the titles of which begin with "0", see here:
http://commons.wikimedia.org/wiki/Special:AllPages/0

In the German language Wikipedia, when you do the same, nothing is shown. Yet, when you append a "'" (single quote) a single
page title is shown, which is correct.
There are several dozens of pages beginning with "0" in the
German language Wikipedia, see here:
http://de.wikipedia.org/wiki/Spezial:Alle_Seiten/0
So, I would expect the initial few be diplayed, when you type
the initial "0".

Maybe the different behavior of the two wikis is owed to the
fact that, the German language Wikipedia has a page title "0",
but I could not verify that.
Comment 1 Brion Vibber 2009-01-21 22:43:55 UTC
It looks like it should work; I can pull a search:

http://de.wikipedia.org/w/api.php?action=opensearch&format=jsonfm&search=0

I see some funky JS errors in firebug when trying to pull the '0' like:

box.getNotificationWithValue is not a function
http://de.wikipedia.org/skins-1.5/common/mwsuggest.js?195xx
Line 125

os_decodeValue("0,5%-Hürde")mwsugges....js?195xx (line 125)
os_createResultTable(Object searchform=searchform searchbox=searchInput, ["0", "0 v. Chr.", "0'00''", 7 more... 0=0 1=0 v. Chr. 2=0'00'' 3=0,5%-Hürde 4=0,5-%-Hürde])mwsugges....js?195xx (line 368)
os_updateResults(Object searchform=searchform searchbox=searchInput, "0", "["0",["0","0 v. Chr.","0'00''","0,5%-H\u00fcrde","0,5-%-H\u00fcrde","0-0","0-1-Gesetz","0-8-15","0-km-Stein","0. Dynastie"]]", "http://de.wikipedia.org/w/api.php?action=opensearch&search=0&namespace=0|4|11")mwsugges....js?195xx (line 344)
os_updateIfRelevant(Object searchform=searchform searchbox=searchInput, "0", "["0",["0","0 v. Chr.","0'00''","0,5%-H\u00fcrde","0,5-%-H\u00fcrde","0-0","0-1-Gesetz","0-8-15","0-km-Stein","0. Dynastie"]]", "http://de.wikipedia.org/w/api.php?action=opensearch&search=0&namespace=0|4|11")mwsugges....js?195xx (line 401)
onreadystatechange()()mwsugges....js?195xx (line 428)
[Break on this error] return decodeURIComponent(value);

It's a little hard to follow, but I think the suggestion table generator is trying to URL-decode the results, which don't appear to be URL-encoded. When it hits the % sign in "0,5-%-Hürde" the URL decoding fails? And then firebug also spits out a totally unrelated error about a null or something. o_O
Comment 2 Purodha Blissenbach 2009-01-22 02:28:48 UTC
The search appears to be good, indeed.

That looks like either debugging the JS-stuff,
or simply coding the % as \0025 so as to avoid
the "stupid" urldecoding attempt.
Comment 3 Krinkle 2011-08-11 11:00:48 UTC
Marking as worksforme. Search front-end has changed a lot in two years, if the bug is stil there (I dont see it on de.wikipedia, '0' returns a few page names correctly), please re-open.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links