Page MenuHomePhabricator

After all translations to a given locale are deleted, the localized page for that locale is not deleted
Closed, ResolvedPublicBUG REPORT

Description

List of steps to reproduce (step by step, including full links if applicable):

What happens?:
The translatable page is not refreshed. The {{delete}} tag and the vandalism remains in the page and therefore in the Speedy Deletion category.

What should have happened instead?:
The translatable page is refreshed and the deleted translations removed, as it happened until not so long ago.

Software version (if not a Wikimedia wiki), browser information, screenshots, other information, etc.:

I am not sure if this the Translate extension or the JobQueue. Tagging both.

Event Timeline

Sidenote: I always use {{#ifeq:{{NAMESPACE}}|Translations|{{speedy|not a translation}}}} in such cases—this shows the deletion template only on the Translations-namespace page (not the actual translated page). I do so to avoid that an administrator accidentally deletes the whole page if only a particular translation unit is wrong, but it would’ve also reduced the problems caused by this bug. (Of course, this namespace check isn’t a substitute for fixing the bug, just a possible workaround.)

The translatable page is not refreshed.

It looks to me like the deletion of the only localized translation unit orphaned the localized page. By that I mean that https://meta.wikimedia.org/w/index.php?title=Special:Translate&group=page-Mailing+lists&language=id&filter=translated&action=translate shows no translation units for language=id and there are no Bahasa Indonesia links in the headers on the various translations of https://meta.wikimedia.org/wiki/Mailing_lists/Overview. I don't think that MediaWiki-extensions-Translate knows that https://meta.wikimedia.org/wiki/Mailing_lists/Overview/id exists at this point. I have a hunch that the /id page will be refreshed once a single language=id translation unit is created.

bd808 renamed this task from After a Translation is deleted, the main translatable page is not updated afterwards to After all translations to a given locale are deleted, the localized page for that locale is not deleted.Jul 6 2022, 10:06 PM

Creating https://meta.wikimedia.org/wiki/Translations:Mailing_lists/Overview/282/id refreshed the page at https://meta.wikimedia.org/wiki/Mailing_lists/Overview/id functionally immediately which I think validates my hypothesis from T312293#8057847 that the issue is the removal of all (or technically the last) localized translation units for a given locale.

abi_ triaged this task as High priority.
abi_ added a subscriber: abi_.

Thanks for investigating this. This issue was introduced in the patch: e4368b4ee56a41e187485e6fc19f464aa06c6bfb

I'll submit a fix to this shortly.

Change 811924 had a related patch set uploaded (by Abijeet Patro; author: Abijeet Patro):

[mediawiki/extensions/Translate@master] Translation unit deletion: Skip translation update if it doesn't exist

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

Change 811929 had a related patch set uploaded (by Abijeet Patro; author: Abijeet Patro):

[mediawiki/extensions/Translate@wmf/1.39.0-wmf.19] Translation unit deletion: Skip translation update if it doesn't exist

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

Change 811929 abandoned by Abijeet Patro:

[mediawiki/extensions/Translate@wmf/1.39.0-wmf.19] Translation unit deletion: Skip translation update if it doesn't exist

Reason:

Submitting new commit

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

Change 811929 restored by Abijeet Patro:

[mediawiki/extensions/Translate@wmf/1.39.0-wmf.19] Translation unit deletion: Skip translation update if it doesn't exist

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

Change 811924 merged by jenkins-bot:

[mediawiki/extensions/Translate@master] Translation unit deletion: Skip translation update if it doesn't exist

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

Change 811929 merged by jenkins-bot:

[mediawiki/extensions/Translate@wmf/1.39.0-wmf.19] Translation unit deletion: Skip translation update if it doesn't exist

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

Mentioned in SAL (#wikimedia-operations) [2022-07-07T13:41:07Z] <urbanecm@deploy1002> Synchronized php-1.39.0-wmf.19/extensions/Translate/tag/PageTranslationHooks.php: af5174528885a72230be7346e355261383e91b5c: Translation unit deletion: Skip translation update if it doesnt exist (T312293) (duration: 03m 32s)

abi_ moved this task from In Review to Done on the Language-Team (Language-2022-July-September) board.

The fix for this bug has been back-ported. Please reopen if the issue persists.