Page MenuHomePhabricator

Unfinished messages/comments offered for translation
Closed, ResolvedPublic

Description

The following are not ready for translation, they are just comments to other developers and even include "Patches welcome!". Please don't waste translators' time offering these for translation.

MediaWiki:Apihelp-createapage-upload-param-wpInFix
MediaWiki:Apihelp-createapage-upload-param-wpPostFix
MediaWiki:Apihelp-createapage-upload-example-1


Message URL: https://translatewiki.net/w/i.php?title=Special:Translate&showMessage=apihelp-createapage-upload-param-wpInFix&group=ext-createapage&language=ia

Event Timeline

ashley triaged this task as Lowest priority.Jan 24 2023, 12:59 PM
ashley subscribed.

Thank you for the feedback. I will argue that the API is a highly technical interface that should never have been made translatable in the first place and that the overwhelming majority of users using the API (in general) have some level of English knowledge; my personal recommendation is to simply skip over the API messages and focus on the actual UI and whatnot, the bits that matter to everyone.

As for the specific examples quoted...yeah, you're right, there is nothing to translate there. Feel free to skip those. (Yes, they will likely skew the statistics a bit, but such is life, alas.)

Now for the boring technical backstory, just for the record: CreateAPage is a rather old extension at this point, having been developed originally at Wikia circa 2007-2008. It followed many of the then-best practises, such as using MediaWiki's sajax interface for the (then-)fancy AJAX functionality in JS code.

Fast-forward to MediaWiki 1.27 (according to mw:Manual:Parameters to index.php), the sajax interface became deprecated (and it was apparently finally removed for good in MediaWiki 1.38). This put a lot of pressure on the few remaining users of sajax: code had to be converted to newer standards so that it would keep functioning in future versions of MediaWiki. For CreateAPage, this meant rewriting the old sajax function(s) as an API module(/modules). That's where i18n sorta comes into play, as API modules are i18n-able and if the messages aren't defined, users will see stuff like <this-or-something-like-this> and that's just ugly.

Of course, the "upload" API in CreateAPage is a massive hack that should simply, well, not exist. It's clunky, it's ugly, it's hardly reusable. In essence, it's pretty much everything an API module should not be. And that's all on me, as I performed the conversion exactly a year ago in 34ee3488a31c074001f0298f64df23c777be0cca. In an ideal world, CreateAPage would just use the standard upload API provided by core and we'd all be happy. Unfortunately, as so often happens to be the case in software development, and especially when you aren't paid nor have a paid team of developers to do your work for you, you gotta make tradeoffs: instead of spending a lot of time rewriting a lot of code and testing out the end result and ironing out all the bugs that will pop out, I took the dirty but functional shortcut of not rewriting code and instead just wrapping the old code in a newer "package", so to speak.

So, really, the call-to-action text you're seeing there is to 1) avoid <pure-ugliness-like-this> and also 2) to encourage hackers to contribute to the codebase and make my crappy-but-functional hacks a bit better. Patches are more than welcome, but no-one should feel pressured to contribute, of course.

For the particular issue that this task is, maybe the best way is to blacklist the messages on TWN to avoid having them to show up altogether for translators or something.

Nikerabbit subscribed.

We can these messages as ignored (will remove existing translations) or optional (not shown unless you go looking for them).

Nikerabbit raised the priority of this task from Lowest to Medium.Feb 7 2023, 12:42 PM
Wangombe changed the task status from Open to In Progress.Feb 21 2023, 8:58 AM
Wangombe claimed this task.

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

[translatewiki@master] CreateAPage: Add messages to ignore for translation

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

Change 891228 merged by jenkins-bot:

[translatewiki@master] CreateAPage: Add messages to ignore for translation

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

Tested on translatewiki.net

image.png (404×1 px, 79 KB)