Outcome
Page migration now works on Translatewiki.net as well.
- translate-language-disabled-source was converted to a warning instead of an error
- Special:Translate was update to handle this warning, and not allow translators to translate to the source language.
- English was removed from the list of disabled languages on translatewiki.net
- QueryMessageCollection api was updated to not throw an error if the group source language is disabled.
Steps to reproduce
- Open Special:PageMigration
- Search in the Textbox for the name of a page that has a translation. Eg: Main Page/fr
- Click on Import
Expected behavior
UI should update and show all message collection for page migration.
Actual behavior
Nothing happens, the UI does not update at all nor does it show any errors.
Additional info
The following API call made from getSourceUnits method in file ext.translate.special.pagemigration.js is failing,
API URL -
/api.php?action=query&format=json&list=messagecollection&mcgroup=page-T160511&mclanguage=en&mcprop=definition
Response -
{ "error": { "code": "translate-language-disabled-source", "info": "The source language of this group is English. Please select another language to translate into.", "*": "See http://127.0.0.1:8080/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce> for notice of API deprecations and breaking changes." } }
Comments from Niklas -
That would mean converting the translate-language-disabled error to warning and making sure Special:Translate still handles it in the same way as it does currently