[go: up one dir, main page]

Page MenuHomePhabricator

Importing translatable pages from another wiki does not properly set revtags
Open, LowPublicBUG REPORT

Description

When a translatable page is imported from another wiki using the maintenance script to do so, the fuzzy and tp:transver revtags are not properly set.


Original bug description:

When the translation interface displays the message "This translation may need to be updated," changes made to the source text are not shown for certain translation units.
Some translation units always display the source text changes correctly, while others consistently fail to display these changes.

Steps to Replicate the Issue (include links if applicable):

What Happens?:

The message "This translation may need to be updated" is shown, but source text changes are not displayed in the translation interface.

What Should Have Happened Instead?:

Changes to the source text should be visible in the translation interface when the message "This translation may need to be updated" is displayed.

Event Timeline

My guess as to the cause of this is either the huge size of the unit, or that the tp:transver tag which records which version of the source text the unit is translating wasn't copied over properly when the page was migrated from Meta-Wiki.

the tp:transver tag which records which version of the source text the unit is translating wasn't copied over properly when the page was migrated from Meta-Wiki.

I think it would be almost impossible to move tp:transver tags across wikis given the revision numbers of the source texts will change, and it would require full history move, not just the latest versions.

The script does move the full history: T347156: Transfer history and revision information when moving translatable bundles between wikis

That of course doesn't change the fact that the import will change revid numbers, and there would have to be some API to get the new-wiki revision for each old-wiki revision. I'm not sure if that is supported by the import code.

There are actually two separate bugs here.

  • Bug 1: Moving a translation page across wikis should copy fuzzy and tp:transver data (with the latter being adjusted for the new wiki's revision IDs). This is not currently done.
  • Bug 2: If a translation unit does not have a tp:transver revtag and is not outdated, and then the source text changes to fuzzy the unit, its tp:transver should be set to the version of the source text before the fuzzy. It's unclear if this can happen in any way other than triggering Bug 1, or very old translation units that were saved before tp:transvers are recorded, but either way it should be fixed.
Pppery renamed this task from Translate: Source text diff not displaying consistently to Importing translatable pages from another wiki does not properly set revtags, which can result in the source text diff not displaying.Sep 8 2024, 4:17 AM

Change #1071358 had a related patch set uploaded (by Pppery; author: Pppery):

[mediawiki/extensions/Translate@master] Fix and test corner cases in fuzzy updating

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

Change #1071358 merged by jenkins-bot:

[mediawiki/extensions/Translate@master] Fix and test corner cases in fuzzy updating and reverting

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

Bug 2 should be fixed by that patch. I'm going to leave this ticket open to track bug 1.

(And in any event it's impossible to fix this retroactively - if the data to show "show differences" isn't there then it isn't there)

Pppery renamed this task from Importing translatable pages from another wiki does not properly set revtags, which can result in the source text diff not displaying to Importing translatable pages from another wiki does not properly set revtags.Sep 21 2024, 5:33 PM
Pppery updated the task description. (Show Details)