Richard Liao | 9 May 05:54
Picon

[Trac-dev] make i18n practicable


Hi,

I'm trying to make a fully translated trac 0.12 based on the trunk(r7002).

What I have done:
1. Fully translated the messages.po file.
2. Fully translated the default wiki pages into our local language: zh_CN.
 (I have noticed new help branch in sandbox, but currently, I have to
translate these wiki pages.)

The problem is: the UI elements are not fully i18n-ed.
1. Some string is not i18n-ed in py files.
e.g.
trac/ticket/web_ui.py: line 308:309
            return tag('Ticket ', tag.em('#', ticket.id, title=title),
                       ' (', shorten_line(summary), ') ', verb)
those should be:
            return tag(_('Ticket '), tag.em('#', ticket.id, title=title),
                       ' (', shorten_line(summary), ') ', _(verb))
How do I submit a patch?

2. Some strings never appear not in genshi template or py files:
e.g.
 trac/ticket/template/ticket.html: line 150
                  <py:if test="field">${field.label or field.name}:</py:if>

 and in  trac/ticket/web_ui.py: line 552:560
 the string of ticket.fields['label'] or ticket.fields['edit_label']
or ticket.fields['name'] is not i18n-ed.
(Continue reading)

Christian Boos | 9 May 09:37
Picon
Favicon

[Trac-dev] Re: make i18n practicable


Hello Richard,

Thanks for pointing out the problematic places left.

Richard Liao wrote:
> Hi,
>
> I'm trying to make a fully translated trac 0.12 based on the trunk(r7002).
>
> What I have done:
> 1. Fully translated the messages.po file.
> 2. Fully translated the default wiki pages into our local language: zh_CN.
>  (I have noticed new help branch in sandbox, but currently, I have to
> translate these wiki pages.)
>
> The problem is: the UI elements are not fully i18n-ed.
> 1. Some string is not i18n-ed in py files.
> e.g.
> trac/ticket/web_ui.py: line 308:309
>             return tag('Ticket ', tag.em('#', ticket.id, title=title),
>                        ' (', shorten_line(summary), ') ', verb)
> those should be:
>             return tag(_('Ticket '), tag.em('#', ticket.id, title=title),
>                        ' (', shorten_line(summary), ') ', _(verb))
> How do I submit a patch?
>   

_(verb) won't work. We rather have to spot the original string 
definitions that can end up in this variable.
(Continue reading)

Gravatar

[Trac-dev] Re: make i18n practicable


-On [20080509 09:37], Christian Boos (cboos <at> neuf.fr) wrote:
>What's the problem here? A text node inside a  <th>, why is that not 
>extracted?

[snip]

>I'd appreciate if this could be fixed at the Genshi/Babel level as well -
>maybe http://genshi.edgewall.org/ticket/223 ?.

I think you answered your own question. I need to play around with the xpath
statements a bit.

--

-- 
Jeroen Ruigrok van der Werven <asmodai(-at-)in-nomine.org> / asmodai
イェルーン ラウフロック ヴァン デル ウェルヴェン
http://www.in-nomine.org/ | http://www.rangaku.org/ | GPG: 2EAC625B
If Winter comes, can Spring be far behind..?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac Development" group.
To post to this group, send email to trac-dev <at> googlegroups.com
To unsubscribe from this group, send email to trac-dev-unsubscribe <at> googlegroups.com
For more options, visit this group at http://groups.google.com/group/trac-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Richard Liao | 9 May 12:42
Picon

[Trac-dev] Re: make i18n practicable


On Fri, May 9, 2008 at 3:37 PM, Christian Boos <cboos <at> neuf.fr> wrote:
>
> Hello Richard,
>
> Thanks for pointing out the problematic places left.
>
> Richard Liao wrote:
>> Hi,
>>
>> I'm trying to make a fully translated trac 0.12 based on the trunk(r7002).
>>
>> What I have done:
>> 1. Fully translated the messages.po file.
>> 2. Fully translated the default wiki pages into our local language: zh_CN.
>>  (I have noticed new help branch in sandbox, but currently, I have to
>> translate these wiki pages.)
>>
>> The problem is: the UI elements are not fully i18n-ed.
>> 1. Some string is not i18n-ed in py files.
>> e.g.
>> trac/ticket/web_ui.py: line 308:309
>>             return tag('Ticket ', tag.em('#', ticket.id, title=title),
>>                        ' (', shorten_line(summary), ') ', verb)
>> those should be:
>>             return tag(_('Ticket '), tag.em('#', ticket.id, title=title),
>>                        ' (', shorten_line(summary), ') ', _(verb))
>> How do I submit a patch?
>>
>
(Continue reading)

Zoom.Quiet | 9 May 13:13

[Trac-dev] Re: make i18n practicable

On Fri, May 9, 2008 at 6:42 PM, Richard Liao <richard.liao.i <at> gmail.com> wrote:
>
> On Fri, May 9, 2008 at 3:37 PM, Christian Boos <cboos <at> neuf.fr> wrote:
>>
>> Hello Richard,
>>
>> Thanks for pointing out the problematic places left.
>>
>> Richard Liao wrote:
>>> Hi,
>>>
>>> I'm trying to make a fully translated trac 0.12 based on the trunk(r7002).
>>>
>>> What I have done:
>>> 1. Fully translated the messages.po file.
>>> 2. Fully translated the default wiki pages into our local language: zh_CN.
>>>  (I have noticed new help branch in sandbox, but currently, I have to
>>> translate these wiki pages.)
>>>
>>> The problem is: the UI elements are not fully i18n-ed.
>>> 1. Some string is not i18n-ed in py files.
>>> e.g.
>>> trac/ticket/web_ui.py: line 308:309
>>>             return tag('Ticket ', tag.em('#', ticket.id, title=title),
>>>                        ' (', shorten_line(summary), ') ', verb)
>>> those should be:
>>>             return tag(_('Ticket '), tag.em('#', ticket.id, title=title),
>>>                        ' (', shorten_line(summary), ') ', _(verb))
>>> How do I submit a patch?
>>>
(Continue reading)

Christian Boos | 9 May 19:26
Picon
Favicon

[Trac-dev] Re: make i18n practicable

Christian Boos wrote:
> Hello Richard,
>
> Thanks for pointing out the problematic places left.
>
> Richard Liao wrote:
>   
>> Hi,
>>
>> I'm trying to make a fully translated trac 0.12 based on the trunk(r7002).
>>
>> What I have done:
>> 1. Fully translated the messages.po file.
>> 2. Fully translated the default wiki pages into our local language: zh_CN.
>>  (I have noticed new help branch in sandbox, but currently, I have to
>> translate these wiki pages.)
>>
>> The problem is: the UI elements are not fully i18n-ed.
>> 1. Some string is not i18n-ed in py files.
>> e.g.
>> trac/ticket/web_ui.py: line 308:309
>>             return tag('Ticket ', tag.em('#', ticket.id, title=title),
>>                        ' (', shorten_line(summary), ') ', verb)
>> those should be:
>>             return tag(_('Ticket '), tag.em('#', ticket.id, title=title),
>>                        ' (', shorten_line(summary), ') ', _(verb))
>> How do I submit a patch?
>>   
>>     
>
(Continue reading)

Christian Boos | 12 May 12:23
Picon
Favicon

[Trac-dev] Re: make i18n practicable


Christian Boos wrote:
> Christian Boos wrote:
>   
>> Hello Richard,
>>
>> Thanks for pointing out the problematic places left.
>>     

Sorry for the monologue, but as there's been some follow-up on this 
topic, I thought I should mention them here as well. In addition, in the 
last part of this message I've made a few suggestions for improving the 
way we're working with the translations and the translators.

>> Richard Liao wrote:
>>   
>>     
>>> Hi,
>>>
>>> I'm trying to make a fully translated trac 0.12 based on the trunk(r7002).
>>> y files.
>>> e.g.
>>> trac/ticket/web_ui.py: line 308:309
>>>             return tag('Ticket ', tag.em('#', ticket.id, title=title),
>>>                        ' (', shorten_line(summary), ') ', verb)
>>> ...
>>
>> The above will be rewritten differently:
>>
>> M_('Ticket %(ticketref)s (%(summary)s) %(verb)s'), 
(Continue reading)

Noah Kantrowitz | 12 May 23:48
Picon
Favicon

[Trac-dev] Re: make i18n practicable


On May 12, 2008, at 6:23 AM, Christian Boos wrote:
>
> Now, on a related note but still on the very "make i18n practicable"
> subject, I've started to improve the documentation related to
> translations. While the level of documentation was good enough for me
> (thanks Jeroen for getting me started on this!), I think more detailed
> guidelines should be given to translators, so that they can more
> effectively contribute.
>
> For me, it makes absolutely no sense that translators contribute
> translations without at the same time running their translated version
> of Trac and verifying how good their translations are in context. A
> given translation that maybe looks fine in the .po file may seem wrong
> once seen in context within Trac (I verified this more than once  
> with my
> own bits of french translations).
>
> As the translators should have a running Trac for their tests, they  
> also
> need to have at hand all the toolchain (Python, Genshi and Babel). The
> only constraint being that everybody needs to have the exact /same/
> versions of the tools, so that there's no variation in the msgids.  
> This
> is what I've started to document in the TracL10N page
> (http://trac.edgewall.org/wiki/TracL10N?version=57) and we should
> continue to do so as the toolchain evolves.
>
> If we can agree on the above, there will be no point in continuing to
> keep the trac/locale/messages.pot in the repository, neither to store
(Continue reading)

Christian Boos | 13 May 07:29
Picon
Favicon

[Trac-dev] Re: make i18n practicable


Noah Kantrowitz wrote:
> On May 12, 2008, at 6:23 AM, Christian Boos wrote:
>   
>> Now, on a related note but still on the very "make i18n practicable"
>> subject, I've started to improve the documentation related to
>> translations. While the level of documentation was good enough for me
>> (thanks Jeroen for getting me started on this!), I think more detailed
>> guidelines should be given to translators, so that they can more
>> effectively contribute.
>>
>> For me, it makes absolutely no sense that translators contribute
>> translations without at the same time running their translated version
>> of Trac and verifying how good their translations are in context. A
>> given translation that maybe looks fine in the .po file may seem wrong
>> once seen in context within Trac (I verified this more than once  
>> with my
>> own bits of french translations).
>>
>> As the translators should have a running Trac for their tests, they  
>> also
>> need to have at hand all the toolchain (Python, Genshi and Babel). The
>> only constraint being that everybody needs to have the exact /same/
>> versions of the tools, so that there's no variation in the msgids.  
>> This
>> is what I've started to document in the TracL10N page
>> (http://trac.edgewall.org/wiki/TracL10N?version=57) and we should
>> continue to do so as the toolchain evolves.
>>
>> If we can agree on the above, there will be no point in continuing to
(Continue reading)

Emmanuel Blot | 13 May 11:53
Picon

[Trac-dev] Re: make i18n practicable


>  Well, IIRC, only asmodai and you shared the opinion that those
>  changesets weren't a problem, others were inclined to think more like
>  me. Plus cmlenz and eblot were not part of that discussion, and I think
>  their opinion matters. So I don't see the problem in presenting my
>  arguments again, in a more structured way, on a discussion list were the
>  topic can reach a wider audience (translators and other Trac contributors).

I have not (yet) followed this topic, but there is a more general
question / issue there:

I'm not living on the IRC channel, and as a very personal opinion I'm
not a big fan of IRC as the primary channel to take decision about the
project. As my contribution to the project is very low, I don't (ahd
should not) mind if that's the way the project main directions are
chosen, but I think it's quite disturbing for people not to get
informed about those decisions. They are not clearly visible (I know
that they are IRC transcript, but it is far less convenient than a
mailing list IMVHO.)

Therefore, it would be nice - when an agreement is reached on the IRC-
 that a project leader post a summary of the decision to the Trac Dev.

There have been a lot of "decisions" that have been taken on the IRC
that I'm/was not aware of - I guess I'm not alone (?) - and for the
sole purpose of a coherent project I think it would be nice to get
these summaries. It's easier to track, easier to get updated, etc.
Maybe a better way would be a Wiki page in TracDev and a post to
trac-dev@ to signal a new page/decision exists?

(Continue reading)

Noah Kantrowitz | 13 May 12:12
Picon
Favicon

[Trac-dev] Re: make i18n practicable


On May 13, 2008, at 5:53 AM, Emmanuel Blot wrote:
>
>> Well, IIRC, only asmodai and you shared the opinion that those
>> changesets weren't a problem, others were inclined to think more like
>> me. Plus cmlenz and eblot were not part of that discussion, and I  
>> think
>> their opinion matters. So I don't see the problem in presenting my
>> arguments again, in a more structured way, on a discussion list  
>> were the
>> topic can reach a wider audience (translators and other Trac  
>> contributors).

Translation has been asmodai's baby, and I am content to let him run  
it as he sees fit. Not to say that other people's options don't  
matter, but he put the time in and knows how things have been working.  
Thats more than enough reason to leave things as is to me. FOSS isn't  
always a democracy.

[snip]

>
> I know that this takes time and its far easier to ask for something
> than to actually do it ;-)
> Nevertheless, I think that would help the project, and help to
> understand why Noah's answers feel sometimes a bit peremptory - to me
> at least.
>
> To sum up:
> The more people (developers, translators, contributors) involved, the
(Continue reading)

Erik Huelsmann | 13 May 14:11
Picon

[Trac-dev] Re: make i18n practicable


Let me state upfront that I don't contribute to the project *at all*,
so that my opinion may be weighted as such, however ...

On 5/13/08, Emmanuel Blot <manu.blot <at> gmail.com> wrote:
>
> >  Well, IIRC, only asmodai and you shared the opinion that those
> >  changesets weren't a problem, others were inclined to think more like
> >  me. Plus cmlenz and eblot were not part of that discussion, and I think
> >  their opinion matters. So I don't see the problem in presenting my
> >  arguments again, in a more structured way, on a discussion list were the
> >  topic can reach a wider audience (translators and other Trac contributors).
>
> I have not (yet) followed this topic, but there is a more general
> question / issue there:
>
> I'm not living on the IRC channel, and as a very personal opinion I'm
> not a big fan of IRC as the primary channel to take decision about the
> project. As my contribution to the project is very low, I don't (ahd
> should not) mind if that's the way the project main directions are
> chosen, but I think it's quite disturbing for people not to get
> informed about those decisions. They are not clearly visible (I know
> that they are IRC transcript, but it is far less convenient than a
> mailing list IMVHO.)
>
> Therefore, it would be nice - when an agreement is reached on the IRC-
>  that a project leader post a summary of the decision to the Trac Dev.
>
> There have been a lot of "decisions" that have been taken on the IRC
> that I'm/was not aware of - I guess I'm not alone (?) -
(Continue reading)

Christopher Lenz | 13 May 20:29
Picon
Picon
Gravatar

[Trac-dev] Re: make i18n practicable


On 13.05.2008, at 11:53, Emmanuel Blot wrote:
>> Well, IIRC, only asmodai and you shared the opinion that those
>> changesets weren't a problem, others were inclined to think more like
>> me. Plus cmlenz and eblot were not part of that discussion, and I  
>> think
>> their opinion matters. So I don't see the problem in presenting my
>> arguments again, in a more structured way, on a discussion list  
>> were the
>> topic can reach a wider audience (translators and other Trac  
>> contributors).
>
> I have not (yet) followed this topic, but there is a more general
> question / issue there:
>
> I'm not living on the IRC channel, and as a very personal opinion I'm
> not a big fan of IRC as the primary channel to take decision about the
> project. As my contribution to the project is very low, I don't (ahd
> should not) mind if that's the way the project main directions are
> chosen, but I think it's quite disturbing for people not to get
> informed about those decisions. They are not clearly visible (I know
> that they are IRC transcript, but it is far less convenient than a
> mailing list IMVHO.)
>
> Therefore, it would be nice - when an agreement is reached on the IRC-
> that a project leader post a summary of the decision to the Trac Dev.
>
> There have been a lot of "decisions" that have been taken on the IRC
> that I'm/was not aware of - I guess I'm not alone (?)

(Continue reading)

Gravatar

[Trac-dev] Re: make i18n practicable


-On [20080513 07:29], Christian Boos (cboos <at> neuf.fr) wrote:
>Well, IIRC, only asmodai and you shared the opinion that those 
>changesets weren't a problem, others were inclined to think more like 
>me.

And thus automatically your idea wins? Because that's what it now looks
like, especially after revising TracL10N to present your workflow.

>So I don't see the problem in presenting my arguments again, in a more
>structured way, on a discussion list were the topic can reach a wider
>audience (translators and other Trac contributors).

After you stumbling onto IRC to throw a 'noise' argument into my face,
arguing it on all fronts and now committing and changing things to already
reflect your point of view I call bullshit that you now want to 'present it
again in a more structured way'. You have an idea in your head and you just
want to enforce it even after I said I would look into it.

Have fun, good luck and best of wishes coordinating all the translations. I
can spend my time on more constructive things.

--

-- 
Jeroen Ruigrok van der Werven <asmodai(-at-)in-nomine.org> / asmodai
イェルーン ラウフロック ヴァン デル ウェルヴェン
http://www.in-nomine.org/ | http://www.rangaku.org/ | GPG: 2EAC625B
If Winter comes, can Spring be far behind..?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac Development" group.
(Continue reading)

Christian Boos | 13 May 19:55
Picon
Favicon

[Trac-dev] Re: make i18n practicable


Hi Jeroen,

Wow, it makes me a bit sad that you're taking things that way.
Please don't - I'm really open to the discussion and don't want to 
enforce "my" way.
I just had the impression that we left the discussion on #IRC with no 
real conclusion, so that's why I wanted to raise the topic again on 
trac-dev. It's nothing /that/ serious, I'd be OK with how things are 
now, but I really thought there would be no problem in discussing and 
trying out alternatives. We're only at the beginning, so experimenting 
should be OK - you had your time for experimenting in the sandbox and I 
didn't join the fun by then, but now that i18n is in trunk (and the more 
urgent stuff for 0.11 is behind me) I felt inclined to join the work on 
i18n, experiment and try to improve things there as well.

Jeroen Ruigrok van der Werven wrote:
> -On [20080513 07:29], Christian Boos (cboos <at> neuf.fr) wrote:
>   
>> Well, IIRC, only asmodai and you shared the opinion that those 
>> changesets weren't a problem, others were inclined to think more like 
>> me.
>>     
>
> And thus automatically your idea wins? Because that's what it now looks
> like, especially after revising TracL10N to present your workflow.
>   

Not a big deal really: 0.12/TracInstall presents the minimal things an 
user has to do in order to get the translations and TracL10N is aimed at 
(Continue reading)

Noah Kantrowitz | 14 May 11:33
Picon
Favicon

[Trac-dev] Re: make i18n practicable

Christian Boos wrote:
> Hi Jeroen,
> 
> Wow, it makes me a bit sad that you're taking things that way.
> Please don't - I'm really open to the discussion and don't want to 
> enforce "my" way.
> I just had the impression that we left the discussion on #IRC with no 
> real conclusion, so that's why I wanted to raise the topic again on 
> trac-dev. It's nothing /that/ serious, I'd be OK with how things are 
> now, but I really thought there would be no problem in discussing and 
> trying out alternatives. We're only at the beginning, so experimenting 
> should be OK - you had your time for experimenting in the sandbox and I 
> didn't join the fun by then, but now that i18n is in trunk (and the more 
> urgent stuff for 0.11 is behind me) I felt inclined to join the work on 
> i18n, experiment and try to improve things there as well.

Why? Was there a problem with the way i18n was progressing? I understand 
that merging to trunk means it is out in the open, but I think you are 
mistaking that for a request for help.

> That was really not the intent - I spent the whole day yesterday 
> improving the translation infrastructure, fixing bugs (some were really 
> critical, I hope you noticed), adding french translations (even if not 
> perfect, for sure), etc. all this while my primary interest is /not/ in 
> the translations, just because it's now in trunk and that I somehow feel 
> co-responsible for it now. Some day I should really stop being the all 
> purpose guy for tackling every outstanding issue, if all that I get back 
> is such kind of acrimonious reaction when I dare moving things forward.
> See? It's easy to get pissed off in such a project when you put a lot of 
> time and energy into it, and for the better or the worse, no one does it 
(Continue reading)

Gravatar

[Trac-dev] Re: make i18n practicable


[Finally got Internet again.]

-On [20080513 19:55], Christian Boos (cboos <at> neuf.fr) wrote:
>I just had the impression that we left the discussion on #IRC with no 
>real conclusion, so that's why I wanted to raise the topic again on 
>trac-dev. It's nothing /that/ serious,

I take translations quite seriously. As does anyone I know who works on this
kind of subject. There's more involved than 'simple translation'.

>We're only at the beginning, so experimenting should be OK - you had your
>time for experimenting in the sandbox and I didn't join the fun by then,
>but now that i18n is in trunk (and the more urgent stuff for 0.11 is behind
>me) I felt inclined to join the work on i18n, experiment and try to improve
>things there as well.

I am not sure how you intended this, but the way you formulated this is
sounds as if I only had a certain right while this was in the branch. And
the way you proceeded did not give me the feeling of joining, but rather
putting down your view as the only way forward.

>Not a big deal really: 0.12/TracInstall presents the minimal things an 
>user has to do in order to get the translations and TracL10N is aimed at 
>translators and developers with much more detailed instructions.

And TracL10N reflects your opinion on the workflow despite my objections.
I totally do not agree with your stance that people should have to run Trac
to contribute translations. And you have shown that you are not aware how
translations in open source projects get handled, which is quite ok, but
(Continue reading)

Christian Boos | 16 May 11:07
Picon
Favicon

[Trac-dev] Re: make i18n practicable


Jeroen Ruigrok van der Werven wrote:
> [Finally got Internet again.]
>
> -On [20080513 19:55], Christian Boos (cboos <at> neuf.fr) wrote:
>   
>> I just had the impression that we left the discussion on #IRC with no 
>> real conclusion, so that's why I wanted to raise the topic again on 
>> trac-dev. It's nothing /that/ serious,
>>     
>
> I take translations quite seriously. As does anyone I know who works on this
> kind of subject. There's more involved than 'simple translation'.
>   

I was saying that /whether to keep the messages.pot in the repository or 
not/ was nothing that serious.
The same for storing periodically the results of automatic runs of 
extract/updates. I still think that's useless and annoying (especially 
if done after every 5 or 10 normal commit) as even no actual changes to 
strings will propagate as hundreds of line offset changes (times the 
number of .po files), but hey, if you think that serves a purpose 
(allowing the translators to start working on up-to-date files), well, 
I'll shut up.
I'm not saying that the translation topic is not important, be it the 
contributions from translators or the i18n work.

>> We're only at the beginning, so experimenting should be OK - you had your
>> time for experimenting in the sandbox and I didn't join the fun by then,
>> but now that i18n is in trunk (and the more urgent stuff for 0.11 is behind
(Continue reading)

osimons | 16 May 13:40
Picon

[Trac-dev] Re: make i18n practicable


On May 16, 11:07 am, Christian Boos <cb...@neuf.fr> wrote:
> Jeroen Ruigrok van der Werven wrote:

> > ... I am uncomfortable with especially when objections
> > seemingly are being overturned. And when that happens I'll just divert my
> > energy and attention elsewhere since my involvement will not matter anyway.
>
> It does matter. Sorry for all this mess (well, we didn't have a decent
> flame on Trac-dev since ages, so this is now fixed :-) ).

I, and no doubt everyone else in the project, agrees that your
contributions are very important. Please stay :-)

This turned out to be a long thread, sometimes deviating, and
sometimes bringing useful insights. To not leave everything hanging,
I'll attempt to summarize some conclusions from my perspective.

1) On the original issue of the thread: The improvements for tagging
text for translations are most welcome. Anything that can help make
sentences easier to understand and translate in the context of the po
file is a good thing. As I've started the nb_NO translation that is
what I found as well. Recent code changes to improve strings and
extractions seems useful, but if someone that knows could document
best practice for text tagging with various examples that would be
very helpful - "i18n for developers" would be much needed and
appreciated.

2) On the workflow and toolchain: The workflow stays according to the
needs of Jeroen to improve and coordinate contributions as before.
(Continue reading)


Gmane