Translations of plugins

Translations of plugins

by Jonas Nockert -
Number of replies: 16

Hi everyone,

knowing Swedish and English, do you think I should include both languages in plugins I release or should I include English only and then add the Swedish translation via lang.moodle.org?

Up to now, I haven't really thought about it and just assumed the first alternative is the best option. Perhaps there are good arguments for doing it some other way instead?

Best regards,

Jonas Nockert

 

 

Average of ratings: -
In reply to Jonas Nockert

Re: Translations of plugins

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Jonas "should I include English only and then add the Swedish translation via lang.moodle.org?"

Yes, that's your only option now. Plugin releases should only include English.

Joseph

In reply to Joseph Rézeau

Re: Translations of plugins

by Jonas Nockert -

Thank you for the reply, Joseph.

Would you mind explaining a bit more about why plugin releases should include only English? From my own testing, including both seem to work fine in the latest stable release of 2.6 so there must be some detail I've overlooked.

Best regards,

Jonas

In reply to Jonas Nockert

Re: Translations of plugins

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi Jonas

Please read this forum post at AMOS about plugins translations.

I think that the only case where translations might be included within a plugin ZIP file would be for plugins classified as 'other'; As they will not have their English language strings available in AMOS.

Currently, Moodle has more than 100 language packs, and maintaining 100 translations within a plugin ZIP file would be humanly impossible. AMOS does a pretty good job of maintaining translations for Moodle core and most add-ons.

If you are proficient at several languages, please consider helping with the  translation of other plugins.

Average of ratings: Useful (2)
In reply to Germán Valero

Re: Translations of plugins

by Jonas Nockert -

Thanks for the link, German (and thank you for translating my Videofile plugin to Mexican Spanish : )

I'm a frequent user of AMOS for Swedish translations and I only know English and Swedish well enough to provide translations for my own plugins in those two languages. I would not dream of maintaining other language translations outside of AMOS.

The link you provided is clear on moving out all other languages than English from plugins' lang folder. However, I wonder if that statement is meant to be applied to my question. Which is really WHY it could be better to provide the Swedish translation of my own plugins through AMOS instead of just providing it with my plugin (given that Swedish is my first language).

That is, my question only regards languages the plugin creator knows and will maintain for the life of the plugin. Sorry for not making that clearer in the original post.

 

Best regards,

Jonas

In reply to Jonas Nockert

Re: Translations of plugins

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi again Jonas, and thanks to German for providing a more detailed explanation than mine.

The case for having all translations on AMOS rather than in a lang folder inside your plugin files is as follows.

After you have put your plugin in the Moodle plugins repository, if you realize there is an error somewhere in your translated strings OR you have forgotten to translate a string...

a) if your Swedish lang strings are inside a yourmodule/lang/se/ folder, then you would have to edit/add those strings and commit a new version of your module to the repository, and tell your Swedish users to upgrade their module to see the new strings.

b) On the contrary, if there is no yourmodule/lang/se/ folder in your module in the Moodle plugins reposiroty but all Swedish strings are on AMOS, once you have edited the strings (and asked the Swedish lang maintainer to accept your translation), then all the end-user has to do is to update their Swedish language pack from within their Moodle site admin interface.

Note.- If you have a set of translated strings both inside your plugin lang folder and on AMOS, the AMOS translations take precedence over the strings in the local folder. Which means that, in my case (a) above, you might still edit/add strings on AMOS and your end-users would only have to update their Swedish lang pack. But really it does not make sense to have translated strings in 2 places (in a local lang folder and on AMOS). Having all translations on AMOS is really the best solution.

I hope this makes things clear,

Joseph

Average of ratings: Useful (3)
In reply to Joseph Rézeau

Re: Translations of plugins

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi,

Thanks Joseph, for explaining the rationale for using only AMOS for plugin translations.

Thanks Jonas, for contributing to Moodle translations in AMOS, and writing plugins for all Moodle users.

I still ignore if the plugins currently classified as 'Other' will eventually have their English strings available at AMOS. That would be very good, as many of those plugins are of great use to Users of Moodle in both English and other languages. For example, the cloze editor has proved extremely useful for assessing veterinary pathology clinical cases at the University where I teach.

Yours sincerely,

Germán Valero

In reply to Joseph Rézeau

Re: Translations of plugins

by Jonas Nockert -

Thanks Joseph! I will move the Swedish translations from my plugins into AMOS when I make new releases.

One thing I realized today is that I can't do this with my plugins that are not approved yet. Approval seems to take about a month (longer now with the recent moodle.org crash) and during that time, the plugins can't be translated using AMOS. Since we're using the plugins in Swedish on our Moodle installation, I have to put the translations within them until they get approved.

One other thing that worries me is that we have to make sure not to install upgrades of my plugins until the Swedish language maintainer has accepted the new translations and new language files has been generated. But that's just a process thing which we should be able to handle.

 

Best regards,

Jonas

In reply to Jonas Nockert

Re: Translations of plugins

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Jonas "One thing I realized today is that I can't do this with my plugins that are not approved yet. Approval seems to take about a month (longer now with the recent moodle.org crash) and during that time, the plugins can't be translated using AMOS. Since we're using the plugins in Swedish on our Moodle installation, I have to put the translations within them until they get approved."

Yes, that's one point I am well aware of, but intentionally did not mention in my previous post in order to simplify things. Actually, this problem happens not only whilst you are waiting for a new plugin to be approved. It also happens if you have made/upgraded a new version of an existing plugin, and have e.g. placed that new/upgraded version on a github (or other repository, or locally). The new/edited strings are in a sort of "limbo", waiting to be translated but not available on AMOS. The only solution I have found is to provisionally keep one (or more) lang folders (other than English) within your plugin files. But then you have to remember to remove those extra lang folders from your plugin distribution when you submit it to the Moodle plugins repository. That's a bit convoluted, I must admit.

Joseph

Average of ratings: Useful (2)
In reply to Joseph Rézeau

Re: Translations of plugins

by David Mudrák -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Plugins guardians Picture of Testers Picture of Translators

and have e.g. placed that new/upgraded version on a github (or other repository, or locally). The new/edited strings are in a sort of "limbo", waiting to be translated but not available on AMOS.

Correct. New strings are registered in AMOS only when a new release is made in the Plugins directory. Having them already updated at github, gitorious or anywhere else does not update them in AMOS. The code outside the Plugins is generally considered as a development version, releases are supposed to be published via Plugins directory.

Note that releasing a new version does not currently include the re-approval process. Releasing a new version in Plugins is also the only way to let users of your plugin be aware of the new version (via the in-built available updates notifications feature).

Average of ratings: Useful (1)
In reply to David Mudrák

Re: Translations of plugins

by Jonas Nockert -

Releasing a new version in Plugins is also the only way to let users of your plugin be aware of the new version (via the in-built available updates notifications feature).

With this discussion in mind, I think it could be useful if the notifications also covered updated language files. I looked in the tracker but couldn't find any issues relating to it, do you know if it has been discussed before?

 

Best regards,

Jonas Nockert

In reply to Jonas Nockert

Re: Translations of plugins

by David Mudrák -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Plugins guardians Picture of Testers Picture of Translators

It has been discussed - MDL-37124. The conclusion was that notification for available lang pack update is not really needed. What is needed is a new admin option "Automatically update language packs" that would update all installed language packs (daily probably).

Average of ratings: Useful (1)
In reply to David Mudrák

Re: Translations of plugins

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

MDL-37124 currently does not have anyone assigned to it, and the latest comment was from january 14th sad

Maybe we should talk about it more? , here in the languages forum or in AMOS ?

In reply to Germán Valero

Re: Translations of plugins

by David Mudrák -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Plugins guardians Picture of Testers Picture of Translators

I re-assigned it back to me. Let me suggest to use the relevant tracker issues to discuss details. Forum posts are easily to get forgotten, if not lost tongueout

In reply to David Mudrák

Re: Translations of plugins

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

HI David,

In my post you quote I was not criticizing the current system, which is quite OK. I was just underlying the lang problem that exists when a developer has an "interim" version on their github. And providing a kind of solution.

May I take this opportunity to say how much I appreciate the AMOS translation system and to thank all those who work on it.approve

Joseph

In reply to Joseph Rézeau

Re: Translations of plugins

by David Mudrák -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Plugins guardians Picture of Testers Picture of Translators
Thanks for your kind words Joseph. It's the most valuable satisfaction an open source developer can get.
In reply to David Mudrák

Re: Translations of plugins

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi David,

I think your work with AMOS has been a tremendous contribution to the usefullness of Moodle for non-English speakers.

I reckon I have abused your expertise and willingness to solve problems too often, by asking you to fix issues that do not fit your job description, but you are the most knowledgeable and efficient programmer I have met for for all things related to Translations strings.

I am deeply indebted to you, and I hope you will continue to do wonders with AMOS and language packs.

Yours sincerely,

Germán Valero