Page MenuHomePhabricator

Language name for Norwegian Bokmål Wikipedia incorrectly listed as "norsk"
Closed, ResolvedPublic


Per T263294#6487346. In the mobile web version of Wikipedia (*, the language name for the Norwegian Bokmål Wikipdia is listed as "norsk" when it should be "norsk bokmål". This was fixed for desktop back in November with the addition of the $wgInterlanguageLinkCodeMap in InitialiseSettings.php, but apparently mobile web doesn't recognize this setting. Ideally it would, so this doesn't have to be fixed in multiple places.

In summary, no should display the name for nb, but only for Wikipedia, not other Wikimedia projects.

Event Timeline

Jdlrobson added a subscriber: Jdlrobson.

Hello! Could you please expand on this bug request as I'm not quite sure what it's referring to. Are you referring to the language results shown in this screenshot?:

If so the label comes from the API request so it's possible the issue actually lays inside the core API so adding the language team.

Screen Shot 2020-10-02 at 1.44.24 PM.png (946×2 px, 88 KB)

Thanks in advance for your help clarifying.

Indeed. The language name is correct in the desktop version:

desktop.png (172×175 px, 9 KB)

But wrong in the mobile version:

mobile.png (203×293 px, 10 KB)

Strangely I'm not seeing an entry for Norsk on

Screen Shot 2020-10-02 at 2.42.59 PM.png (888×2 px, 86 KB)

How can I get the Norsk item to show up on mobile?

Thanks for your patience with me!

The API response in the below URL needs to be updated to consider $wgInterlanguageLinkCodeMap|autonym|langname&llinlanguagecode=en&lang=en

I'm not sure who maintains this API, but no doubt we will need help from language team and/or platform engineer to fix the API here as Minerva is just rendering the data returned by the API.

Nikerabbit added a subscriber: Nikerabbit.

This shouldn't be too difficult to fix, assuming there are no unexpected consequences of changing it there. I'll bring this up in our sprint planning.

Thanks @Nikerabbit. I am happy to help review and test.

Pginer-WMF triaged this task as Medium priority.Oct 7 2020, 1:14 PM

Change 632916 had a related patch set uploaded (by Nikerabbit; owner: Nikerabbit):
[mediawiki/core@master] Apply InterlanguageLinkCodeMap in Action API

There is a risk of breakage if someone uses the lang property in unexpected ways, link constructing the target url manually or indexing the results directly. I am not sure if it should be kept back and perhaps a new property be added.

Change 632916 merged by jenkins-bot:
[mediawiki/core@master] Apply InterlanguageLinkCodeMap in Action API

Screen Shot 2020-10-22 at 12.36.05 PM.png (918×2 px, 97 KB)

This is fixed! yay!