Using AMOS tool for language pack translation

Small changes to AMOS

 
Picture of koen roggemans
Small changes to AMOS
by koen roggemans - Sunday, 20 October 2013, 3:01 AM
Language pack maintainers

Hi all,

After a little discussion David and I had on AMOS improvements, two changes were made:

  • David made that contributions that are in review-state while all strings are already in the language pack, those contributions are automatically marked as accepted and disappear from the contributions list. We concluded that those contributions were applied and the language pack maintainer just forgot to mark them as accepted. That manual step is unnecessary too. A daily script reviews those now.
    That said: there is quite a long list of strings in review with that are not yet in the language pack. Please keep them as short as possible in that status, since new contributors have no way of knowing that someone else has done that work already. The same goes for the new contributed strings. 
    The aim is to keep the contributions list empty.
  • There were lots of languages with the same, only one or no thousand and decimal separator in langconfig. That can cause problems in quiz. I went through all the language packs with a problem and did something there I thought was right smile. Trust me or check it. Some languages have a space as a thousand separator. I have it in Dutch too, but not sure it is OK. Please report if you see problems with it.

The next Moodle version is on it's way. As far as I can see, there are about 500 new strings. We are in code freeze, which means that it is still possible that some new components will not make it into the release. That should not happen anymore, once we have a beta release. That is typically the time to start translating.

Thank you all for your ongoing effort in making Moodle translated. Children/youngsters need their educational tools in their own language and you make that happen every day!

Kind regards

Koen

Picture of German Valero
Re: Small changes to AMOS
by German Valero - Tuesday, 22 October 2013, 10:39 PM
Language pack maintainers

Thanks Koen and David,

These news are good news smile

Keep on the good work.

Picture of German Valero
Re: Small changes to AMOS
by German Valero - Tuesday, 22 October 2013, 11:04 PM
Language pack maintainers

Koen,

International spanish  (2.5 branch downloaded 1 minute ago) still has the same symbol for decimal separator and list separator.  This will wreak havoc in quiz calculations using formulas sad

$string['decsep'] = ',';

$string['listsep'] = ',';

Can you please fix this for all languages ?

THANKS A LOT.

Picture of koen roggemans
Re: Small changes to AMOS
by koen roggemans - Monday, 28 October 2013, 6:10 PM
Language pack maintainers

Hi German,

Thanks for pointing this out. I wasn't aware of that problem yet.

David changed the script for checking the language pack for the separators, so now I have an overview of where it goes wrong. 

I think the best thing to do is to make the list separator a ; in all languages where there is a problem. That is reflected in the documentation and that way there is definitely no overlap with the decimal separator. I don't know why ; is not used in English too - it would make life a little bit easier smile

Picture of David Mudrák
Re: Small changes to AMOS
by David Mudrák - Tuesday, 29 October 2013, 3:00 AM
Language pack maintainers

Thanks German for raising this and thanks to Koen for having this under radar.

Just for the reference, the listsep string has been introduced in https://github.com/moodle/moodle/commit/76317c73a28e66ee78015adbeb079936697881e0#diff-fc237b0e49ba865fb4a070aa1ea209deR9 and the comment there clearly suggests to use the semi-colon if the comma is already in use.

For the reference, initial values of the listsep were set in https://github.com/mudrd8mz/moodle-lang/commit/bd3cbc1834356f87c3e8d6bad32e69cec59f94e4

HTH

Picture of German Valero
Re: Small changes to AMOS
by German Valero - Tuesday, 29 October 2013, 3:39 AM
Language pack maintainers

Thanks Koen and David for fixing this issue for all languages smile

This certainly will help some troubled teachers (a few in México and many in Spain) that use the International Spanish pack smile

One tiny doubt I keep: Will the English language pack keep the (current) comma as listsep?

or will the listsep symbol eventually be replaced by a semi-colon, as Koen commented ?

Yours sincerely grateful,

Germán Valero

Picture of David Mudrák
Re: Small changes to AMOS
by David Mudrák - Wednesday, 30 October 2013, 1:26 AM
Language pack maintainers

Will the English language pack keep the (current) comma as listsep?

Yes, I am not aware of any planned change here.

As far as I can see, Koen has fixed all language pack so there should be no collision between decsep and listsep now. Thanks a lot Koen.

Picture of Joseph Rézeau
Re: Small changes to AMOS
by Joseph Rézeau - Wednesday, 30 October 2013, 2:26 AM
 

koen "I don't know why ; is not used in English too - it would make life a little bit easier"

I agree. The semi-colon ";" is the currently admitted list separator in English (as in French). It should be corrected in Moodle lang/en.

Jospeh

Picture of German Valero
Re: Small changes to AMOS
by German Valero - Wednesday, 30 October 2013, 3:44 AM
Language pack maintainers

Joseph 'The semi-colon ";" is the currently admitted list separator in English (as in French). It should be corrected in Moodle lang/en.'

But the French language pack currently has a comma as listsep, as English does, and Mexican Spanish  does, and many more language packs do.

Should we change them ? or should we follow the saying 'if it ain't broke, don't fix it' ? thoughtful

Comments are welcomed from other language pack maintainers, specially from academics familiar with the English grammar (as Joseph).

2.5 [listsep,core_langconfig]
,
fr
Nicolas
Re: Small changes to AMOS
by Nicolas Martignoni - Wednesday, 30 October 2013, 4:15 AM
Language pack maintainers

Hi German,

As the french language maintainer, I don't know really if there's a standard for the list separator. But if it's the case, I would be pleased to change it myself.

Whenever possible, I tend to prefer changing the things myself, so I know what's going on.

And sorry, I can't comment about english grammar smile

Nicolas
Re: Small changes to AMOS
by Nicolas Martignoni - Wednesday, 30 October 2013, 4:32 AM
Language pack maintainers

German,

I just verified the listsep value for french, and it's not a comma, but a semi-colon, even in 2.5, and was not recently changed. Where did you get your french langpack?

2.5 [listsep,core_langconfig]
,
 
fr
;
2.6 [listsep,core_langconfig]
,
 
fr
;
Picture of German Valero
Re: Small changes to AMOS
by German Valero - Wednesday, 30 October 2013, 10:28 AM
Language pack maintainers

Hi Nicolas & Joseph,

I apologize.

Silly old me. I seem to have magnified excessively my screen when looking at AMOS and I got the wrong impression.

I have changed the list separator in Mexican Spanish to semi-colon too.

Picture of koen roggemans
Re: Small changes to AMOS
by koen roggemans - Wednesday, 30 October 2013, 1:47 PM
Language pack maintainers

i don't know if we can just change the list separator without breaking things on peoples sites. If formulas are defined, they might break.

Nicolas
Re: Small changes to AMOS
by Nicolas Martignoni - Wednesday, 30 October 2013, 2:52 PM
Language pack maintainers

To be clear: I don't ask any change. IMHO we should only change what is necessary. As said by German: if It isn't broken, don't fix it. 

Picture of koen roggemans
Re: Small changes to AMOS
by koen roggemans - Wednesday, 30 October 2013, 3:55 PM
Language pack maintainers

yes, that is what I mean too smile

Its just a shame that this can cause so much unclarity of what the list separator is in a given language.

I'll see if there is a help text to do something with, because they are language sensitive.

Nicolas
Re: Small changes to AMOS
by Nicolas Martignoni - Wednesday, 30 October 2013, 4:33 AM
Language pack maintainers

OK, I just made some readings.

It seems that in french (at least) there's no such thing as a "standard" list separator. Worse, the quasi-standard Excel seems to be pretty inconsistent in this matter.

In french (France localisation), the list separator is a semi-colon, as Joseph writes just above. But...

In french (Switzerland localisation), this very list separator is a comma smile

As the most "official" document on the matter is the RFC-4180, I tend to go with it. But YMMW.

Cheers, Nicolas

PS. Did we open here a potential flame war wink

Picture of Joseph Rézeau
Re: Small changes to AMOS
by Joseph Rézeau - Wednesday, 30 October 2013, 6:49 PM
 

Hi, all "semi-colon aficionados". wink

Some random thoughts...

1.- In Moodle 2.6DEV, the listsep string is only used in 4 places (outside of the lang file where it's defined):

  • admin\tool\uploadcourse\classes\step1_form.php;
  • admin\tool\uploaduser\user_form.php;
  • lib\mathslib.php
  • and mod\data\export_form.php.

2.-In Moodle "list separator" is used for 2 different uses. And I would add a third.

a) In export/import operations, listsep is used as a data separator, e.g. in CSV files. That's the use that Nicolas is referring to in this link: http://tools.ietf.org/html/rfc4180.

b) In mathslib, function localize($formula) uses both listsep and decsep, which I do not understand the need for, not being a mathematician. All I can say is that these are 2 unrelated concepts, which may have different strings in different languages.

c) As a non-mathematician and non professional programmer, I misunderstood the point of the listsep and decsep debate. When I wrote that the semi-colon was the standard list separator in French (and in English), I was thinking in terms of typography and of 'lists" of words or parts of sentences. For example, in my point #1 above in this message, I have formatted my list of the 4 php files according to what I take are standard typographic rules (followed by scientific publications). An enumeration is formatted starting with the "descriptive" part, followed by a colon, then by each part of the enumeration, each separated from the next by a semi-colon, except that the last 2 parts are separated/linked by "and", and of course a full-stop at the end.

At the moment, there is no typographical list separator string in Moodle. So, programmers use whatever seems OK to them, and maybe OK in English but not in other languages. For instance, I've had a bone of contention with Tim for a number of years about the way that the Correct answer to Match questions is displayed.

I hope I have not added even more obscurity to the current debate.

Joseph

PS.- For amateurs of punctuation, syntax, language, etc. I recommend Lynne Truss's Eats, Shoots & Leaves, which does have a chapter about the comma and semi-colon.

Nicolas
Re: Small changes to AMOS
by Nicolas Martignoni - Thursday, 31 October 2013, 3:37 AM
Language pack maintainers

Thanks Joseph for these very useful clarifications.

Ad a), you make a good point here that we maybe need another string for a data separator, as the actual listsep is uses for two different and possibly contradictory uses (data and list separator).

Ad b), if I understand correctly, the function localize format a number in a proper localisation (and unlocalize revert this formatting), that's all. Not rocket science here.

Ciao, Nicolas