Page MenuHomePhabricator

If the translation in progress was once published, deleting it should move it to published status
Closed, ResolvedPublic

Description

Translators often publish and continue the translation by making the translation in draft state. This kind of translations appears in "In prograss" set in dashboard. But they can be deleted by translators. That results a case where the data of a published translation is deleted.

We should not allow deleting a trnaslation if it was once published.

From ApiContentTranslationDelete:

	ContentTranslation\Translator::removeTranslation( $translationId );

This is a hard delete and disconnect the translation from translator. That should not happen if the translation was once published. More over, the translation should appear under "Published translations" set

	ContentTranslation\Translation::delete( $translationId );

This makes the status of translation as 'deleted'. Ideally the status should go back to 'published' because the translation was once published.

	ContentTranslation\Draft::delete( $translationId );

This makes the draft entry hard deleted. Which should not happen because the draft is required for parallel corpora. See T119489: Avoid deleting the saved translation once translation published to wiki

Event Timeline

santhosh created this task.Jan 18 2016, 4:50 AM
santhosh updated the task description. (Show Details)
santhosh raised the priority of this task from to Needs Triage.
santhosh added subscribers: santhosh, Nikerabbit.
Restricted Application added subscribers: StudiesWorld, Aklapper. · View Herald TranscriptJan 18 2016, 4:50 AM

@Nikerabbit, @Amire80, @Pginer-WMF, please validate the above expectations

I definitely agree on not deleting stuff, and I also think that the current UI should not be changed so maybe the title should be reworded to better name the problem.

Agree.
When deleting a translation that was once published, it makes sense to keep it in the "published" list.

Amire80 triaged this task as Normal priority.Jan 20 2016, 3:32 PM
Amire80 set Security to None.
Amire80 moved this task from Backlog to Parallel corpora on the ContentTranslation-Release8 board.
Nikerabbit renamed this task from Do not allow deleting the drafts from the dashboard, if the translaiton was once published to Do not allow deleting the drafts from the dashboard, if the translation was once published.Jan 20 2016, 4:42 PM
Amire80 moved this task from Needs Triage to CX8 on the ContentTranslation board.Feb 2 2016, 8:08 PM
santhosh claimed this task.
santhosh renamed this task from Do not allow deleting the drafts from the dashboard, if the translation was once published to If the translation in progress was once published, deleting it should move it to published status.Feb 10 2016, 5:08 AM

Change 269600 had a related patch set uploaded (by Santhosh):
Do not delete the translation which was once published

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

santhosh moved this task from Backlog to In Review on the LE-CX8-Sprint 2 board.Feb 10 2016, 5:11 AM

Change 269600 merged by Nikerabbit:
Do not delete the translation which was once published

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

Nikerabbit moved this task from In Review to QA on the LE-CX8-Sprint 2 board.Feb 12 2016, 7:35 AM
Arrbee added a subscriber: Arrbee.Feb 25 2016, 6:13 PM

Works normally except for one known situation documented in this ticket T128106 - Drafts created out of duplicate suggestion articles are not discarded

Arrbee moved this task from QA to Done on the LE-CX8-Sprint 2 board.Feb 25 2016, 6:13 PM
santhosh closed this task as Resolved.Apr 20 2016, 9:25 AM