Trying to create a saved diff for T342622: Clicking Prepare multiple times on Special:PagePreparation results in multiple diffs being appended
Description
Details
Subject | Repo | Branch | Lines +/- | |
---|---|---|---|---|
PagePreparation: Add/Improve error handling | mediawiki/extensions/Translate | master | +106 -63 |
Related Objects
- Mentioned In
- T348497: Special:PagePreparation improvements [FY2023/24-Q2]
T342695: Have a way to take text from Special:PagePreparation "prepared" page text straight into the edit screen
T342651: Special:PagePreparation should handled pages with translation markup better (or do nothing)
T342622: Clicking Prepare multiple times on Special:PagePreparation results in multiple diffs being appended - Mentioned Here
- T342651: Special:PagePreparation should handled pages with translation markup better (or do nothing)
T342622: Clicking Prepare multiple times on Special:PagePreparation results in multiple diffs being appended
Event Timeline
I don't think it's feature is completely broken, as it worked on an untranslated page - https://www.mediawiki.org/w/index.php?title=User%3AReedy%2FTest&diff=6041122&oldid=566646
Either way, it shouldn't be failing silently and doing apparently nothing...
Trying another page https://www.mediawiki.org/wiki/Help:Categories/Test it seems there is again weirdness in the diff...
And on Publish,
{ "error": { "code": "pt-shake-empty", "info": "Empty translation unit for marker \"3\".", "*": "See https://www.mediawiki.org/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/postorius/lists/mediawiki-api-announce.lists.wikimedia.org/> for notice of API deprecations and breaking changes." }, "servedby": "mw-api-ext.eqiad.main-5cf9879585-tlrxx" }
Which is seemingly suppressed by the frontend JS. Nothing is shown at all.
It seems it does some weird duplication of syntax etc too. Which really becomes T342651: Special:PagePreparation should handled pages with translation markup better (or do nothing).
Change 944244 had a related patch set uploaded (by Reedy; author: Reedy):
[mediawiki/extensions/Translate@master] WIP: PagePreparation: Add fail() handlers to api calls
Change 944244 merged by jenkins-bot:
[mediawiki/extensions/Translate@master] PagePreparation: Add/Improve error handling
We're ensuring that we now display errors (page to prepare does not exist) to the user. We've also added failure handlers for API call to display sensible/actionable error messages to users.
@abi_ Please attach F38101348 (see https://www.mediawiki.org/wiki/Phabricator/Help#File_visibility).
Yay!
I'm sure there's always more we can do, but we're catching some (most?) of the errors that were annoying me at the time.
Can always file tasks down the line if/when I or anyone else finds any issues :)