Page MenuHomePhabricator

Notify translators when messages have been changed
Closed, ResolvedPublic4 Estimated Story Points

Description

In T348501: Minimal prototype implementation for watching message groups, we added functionality that notifies translators when there are new messages in their group or messages have been deleted. A common request received since then is to be notified when messages under a message group are changed.

Event Timeline

abi_ triaged this task as Medium priority.May 2 2024, 8:14 AM
abi_ moved this task from Backlog to tux on the MediaWiki-extensions-Translate board.

Change #1068663 had a related patch set uploaded (by Wangombe; author: Wangombe):

[mediawiki/extensions/Translate@master] Notify subscribed translators of fuzzy messages

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

• Wangombe changed the task status from Open to In Progress.EditedSep 2 2024, 2:15 PM
• Wangombe claimed this task.
• Wangombe subscribed.

A new message is required that would serve to notify translators when messages change.

"notification-body-translate-mgs-message-updated": "Updated $1 {{PLURAL:$1|message|messages}}"

The notification name:

translate-mgs-message-updated

These names are open to feedback should there be any suggestions around them.

We are planning to send different notifications when messages are added and when messages are updated. As an example:

  • When marking a page for translation, new messages could have been added while others have been updated. In this case, the notification could read:
Added 2 messages. Updated 5 messages

... or we could send two different notifications; one indicating that messages have been added and another indicating that messages have been removed.

  • In the event that no messages were updated:
Added 2 messages. Updated 0 messages

... or we could send one notification for added messages and none for updated messages

In the first example, there's a risk of wasting precious notification real estate with sending multiple notifications. I think consolidating the notifications would be the best approach. This is welcome for discussion.

image.png (850×676 px, 80 KB)

I think simplest would be Along the lines of "X new or updated messages" assuming the primary intention is just to alert translators that there is something for them to do. If more details are needed then we need multiple messages: "X new", "X updated", "X new and Y updated".

I think going with X new or updated messages should be fine. We can re-iterate if needed

abi_ set the point value for this task to 4.Sep 7 2024, 2:14 PM

Change #1072902 had a related patch set uploaded (by Wangombe; author: Wangombe):

[mediawiki/extensions/Translate@master] ImportExternalTranslationsMaintenanceScript: Send notifications

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

Change #1072903 had a related patch set uploaded (by Wangombe; author: Wangombe):

[mediawiki/extensions/Translate@master] ManageGroupsSpecialPage: add group subscription notification

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

Change #1068663 merged by jenkins-bot:

[mediawiki/extensions/Translate@master] Notify translatable page & message bundle subscribers of fuzzy messages

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

Change #1072902 merged by jenkins-bot:

[mediawiki/extensions/Translate@master] ImportExternalTranslations: Send notifications for new messages

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

Change #1072903 merged by jenkins-bot:

[mediawiki/extensions/Translate@master] ManageGroupsSpecialPage: Add notifications for imported messages

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

Tested this on translatewiki.net with message bundles and translatable pages. Works as expected.