Page MenuHomePhabricator

Reserved plural keywords mixed with other keys when message doesn't contain plural
Closed, ResolvedPublicBUG REPORT

Description

Translatewiki.net logs,

[25-Feb-2020 05:30:24 UTC] Exception occurred while processing group: eol-website.
Exception: MWException: Parsing /resources/projects/eol-website/config/locales/pt-BR.yml failed: Reserved plural keywords mixed with other keys: other, pie_prompt. in /srv/mediawiki/tags/2020-02-19_15:27:30/extensions/Translate/ffs/SimpleFFS.php:131
Stack trace:
#0 /srv/mediawiki/tags/2020-02-19_15:27:30/extensions/Translate/messagegroups/FileBasedMessageGroup.php(54): SimpleFFS->read('pt-br')
#1 /srv/mediawiki/tags/2020-02-19_15:27:30/extensions/Translate/utils/MessageGroupCache.php(214): FileBasedMessageGroup->load('pt-br')
#2 /srv/mediawiki/tags/2020-02-19_15:27:30/extensions/Translate/utils/ExternalMessageSourceStateComparator.php(94): MessageGroupCache->isValid(0)
#3 /srv/mediawiki/tags/2020-02-19_15:27:30/extensions/Translate/utils/ExternalMessageSourceStateComparator.php(83): ExternalMessageSourceStateComparator->processLanguage(Object(FileBasedMessageGroup), 'pt-br', Object(MediaWiki\Extensions\Translate\MessageSync\MessageSourceChange))
#4 /srv/mediawiki/tags/2020-02-19_15:27:30/extensions/Translate/scripts/processMessageChanges.php(86): ExternalMessageSourceStateComparator->processGroup(Object(FileBasedMessageGroup), Array)
#5 /srv/mediawiki/tags/2020-02-19_15:27:30/maintenance/doMaintenance.php(107): ProcessMessageChanges->execute()
#6 /srv/mediawiki/tags/2020-02-19_15:27:30/extensions/Translate/scripts/processMessageChanges.php(176): require_once('/srv/mediawiki/...')
#7 {main}

Cause of issue: https://github.com/EOL/eol_website/commit/d1cf755bb82982c35b109d2e8b27c3251a174218#diff-e511459ce3b2add887868cb235492a53R726

There are other instances of this - https://github.com/EOL/eol_website/blob/7a579e184a551b78f118753c4ec7e870e0528a02/config/locales/fr.yml#L1117

Have to investigate what is causing this particular error for pt-br language.

Event Timeline

Change 576053 had a related patch set uploaded (by Abijeet Patro; owner: Abijeet Patro):
[mediawiki/extensions/Translate@master] Allow other keys in messages with the "other" plural keyword

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

abi_ triaged this task as Medium priority.

Change 576053 merged by jenkins-bot:
[mediawiki/extensions/Translate@master] Allow other keys in messages with the "other" plural keyword

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

abi_ moved this task from In Review to Done on the Language-Team (Language-2020-January-March) board.

The related change has been deployed. Tested by running autoimport manually.