https://bugzilla.wikimedia.org/show_bug.cgi?id=22242
Summary: en:wikipedia SQL interwiki table
Product: Wikimedia
Version: unspecified
Platform: All
OS/Version: All
Status: NEW
Severity: major
Priority: Normal
Component: Interwiki links
AssignedTo: [email protected]
ReportedBy: [email protected]
Hi,
I recently noticed that the API for Wikipedia adds [[U+FFFD]] (they eventually
show up like question marks in a little diamond) at the end of all strings
returned by the following API request:
*
http://en.wikipedia.org/w/api.php?action=query&meta=siteinfo&siprop=interwikimap
My bot bumped on this on <i>en.wikipedia.org</i> and was unable to get the
interwiki list from the site.
Strangely enough this seems to happen only here as other Wikipedia wikis don't
exhibit this behaviour. A few examples:
*
http://fr.wikipedia.org/w/api.php?action=query&meta=siteinfo&siprop=interwikimap
*
http://pt.wikipedia.org/w/api.php?action=query&meta=siteinfo&siprop=interwikimap
*
http://zh.wikipedia.org/w/api.php?action=query&meta=siteinfo&siprop=interwikimap
My guess is that the database table “interwiki” contains extra characters after
each field, on my MediaWiki server this is what I see:
mysql> desc interwiki ;
+-----------+---------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-----------+---------------+------+-----+---------+-------+
| iw_prefix | varbinary(32) | NO | PRI | NULL | |
| iw_url | blob | NO | | NULL | |
| iw_local | tinyint(1) | NO | | NULL | |
| iw_url | tinyint(1) | NO | | NULL | |
+-----------+---------------+------+-----+---------+-------+
you can confirm that all “prefix” fields in the XML returned by
<i>en.wikipedia.org</i> are exactly 32 characters long so the var in
varbinary() is not used or the code reading that field has a problem.
Thank, Regards,
--
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l