Page MenuHomePhabricator

$wgDisabledVariants should disable variants based on "the language code with converter"
Open, Needs TriagePublic

Description

$wgDisabledVariants should disable variants based on "the language code with converter"

The DisabledVariants configuration option is used for multivariant sites.

However, it cannot distinguish the variant disabled for which converter, which means it won't work well when a language appeared as variant in multiple converters in multilanguage sites.

We should introduce new DisabledLanguageVariants configuration option to replace it.

$wgDisabledLanguageVariants= [
    'sr' => [
        'sr-el',
    ],
    'zh' => [
        'zh-tw',
    ],
];
$wgDisabledLanguageVariants['zh'] = [
    'zh-tw',
];
$wgDisabledLanguageVariants['zh'][] = 'zh-tw';

Version: 1.39.2
Severity: normal

See also:

Event Timeline

Change 906625 had a related patch set uploaded (by Winston Sung; author: Winston Sung):

[mediawiki/core@master] Implement DisabledLanguageVariants config option

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

Change 990084 had a related patch set uploaded (by Winston Sung; author: Winston Sung):

[mediawiki/extensions/Wikibase@master] Migrate to DisabledLanguageVariants config option

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

Winston_Sung changed the task status from Open to In Progress.Jan 14 2024, 4:45 PM
Winston_Sung claimed this task.
Aklapper changed the task status from In Progress to Open.Apr 11 2025, 10:19 PM

Resetting task status from "In Progress" to "Open" as this task has been "in progress" for more than one year (see T380300). Feel free to set that status again, or rather break down into smaller subtasks.

Change #906625 abandoned by Hashar:

[mediawiki/core@master] Implement UseLanguageVariants config option

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

Change #906625 restored by Thcipriani:

[mediawiki/core@master] Implement UseLanguageVariants config option

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