Page MenuHomePhabricator

"Missing in" is shown for the language of the same Wikipedia on mobile, when it's the browser's preferred language (Accept-Language)
Closed, ResolvedPublicBUG REPORT

Description

To reproduce:

  1. Make sure that Content Translation is enabled in the Setswana Wikipedia (tn.wikipedia.org).
  2. In the browser preferences, set Setswana (tn) as your top preferred language for showing websites.
  3. Go to https://tn.m.wikipedia.org/wiki/Aforika_Borwa#/languages
  4. Observe: "Missing in Setswana" is shown at the top of the language.

Expected: This is the Setswana Wikipedia, so it's not supposed to be suggested.

I can see the same bug in the Hebrew Wikipedia, and other languages where Section Translation is enabled by default.

Event Timeline

The getMissingFrequentLanguages need a filter for current language, similar to the filtering we did in ULS relevant languages entrypoint

Also, mw.config.get( 'wgSectionTranslationMissingLanguages', [] ) is returning the current language. That is not right.

Change 841039 had a related patch set uploaded (by Santhosh; author: Santhosh):

[mediawiki/extensions/ContentTranslation@master] mffrequentlanguages entrypoint: Avoid showing current language as missing

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

Change 841039 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] mffrequentlanguages entrypoint: Avoid showing current language as missing

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

Nikerabbit changed the subtype of this task from "Task" to "Bug Report".Oct 27 2022, 8:46 AM

@santhosh need a bit of help here. I did go to the browser settings to change this language to Tswana follow the instructions in the first image below. Mind you the "Display google chrome in this language" option is only available on windows, I use a Mac. So I am not sure if that affects anything.

I did set the Tswana language to the top ( second image)

Restarting chrome and then going to the link: https://tn.m.wikipedia.org/wiki/Aforika_Borwa#/languages I do see the suggested languages as below ( third image). Is that expected ?

Screen Shot 2022-11-20 at 10.00.57 PM.png (652×1 px, 144 KB)

Screen Shot 2022-11-20 at 10.02.01 PM.png (722×1 px, 104 KB)

Screen Shot 2022-11-20 at 10.08.23 PM.png (760×1 px, 68 KB)

You are seeing Vietanamese because of 'tn' in its English name. This is similar to the situation I explained in https://phabricator.wikimedia.org/T320382#8385627. So use a display language like bn or ml. Sorry for the confusion. The fuzzy matching logic for language search tightly depends on current display language. That makes the experience different for different people.

got it thanks for the explanation. Marking this passed