Page MenuHomePhabricator

Map dummy language codes in sites
Open, MediumPublic

Description

The script that populates the sites table assumes that the subdomain is the content language code. This is not true for all wikis. This patch introduces a mapping to fix this issue on the fly, based on $wgDummyLanguageCodes.

This is driven by the need to avoid "bad" language codes when creating wikidata items from the client, when "linking" two pages on different wikis. When we do this, we use the language code from the sites table for the labels of the new item. We would like to forbid "dummy" languages in labels and descriptions, for consistency.

WARNING: Watch for unintended side effects, such as T137404: Interwiki links display in triple on certain articles.

Event Timeline

Change 293700 had a related patch set uploaded (by Adrian Heine):
Map dummy language codes in sites

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

Orphaned task (member of closed project(s) only) → tagging with the seemingly closest relevant tag.

Change 293700 abandoned by Daniel Kinzler:
Map dummy language codes in sites

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