[Openstack-i18n] "Warning: none, Errors: 1" from the difference of number of lines

Ying Chun Guo guoyingc at cn.ibm.com
Tue Oct 6 15:33:00 UTC 2015


Hi,

According to clarkb and doug-fish's input, "msgfmt --check-format" will 
check
the heading newlines and trailing newlines in the source string and 
translation string. If they
are not same, it will cause a failure in the gate testing of Gerrit.
So we do want Zanata to enable these validations.

The complains from translators are about errors of different line numbers,
for example: "Not enough lines in translation (expected 2, found 1)".
After reading the source pot files, I noticed there were some meaningless 
newlines
in the source pot files. These newlines come from HTML files.
For example: 
http://git.openstack.org/cgit/openstack/horizon/tree/openstack_dashboard/locale/django.pot#n3486
So I don't think it's useful to keep the line numbers exactly same.

@ Alex, in the web UI of Zanata, the validation of "leading/trailing 
newline (\n)"
is described as "check for consistent leading and trailing newline (\n)". 
But actually, the validation will also check for the same line numbers of 
source string 
and translation string. Do you agree it is a bug ?
I think we don't need the check of same line numbers.
If you agree it is bug, I will report it.

Best regards
Ying Chun Guo (Daisy)


Andreas Jaeger <aj at suse.com> wrote on 10/06/2015 02:42:00 PM:

> From: Andreas Jaeger <aj at suse.com>
> To: Alex Eng <aeng at redhat.com>
> Cc: Openstack-i18n Openstack-i18n <openstack-i18n at lists.openstack.org>
> Date: 10/06/2015 03:13 PM
> Subject: Re: [Openstack-i18n] "Warning: none, Errors: 1" from the 
> difference of number of lines
> 
> On 2015-10-05 21:51, Alex Eng wrote:
> > Hi Andreas,
> >
> > The reason translations can't be save when newline character doesn't
> > match with source is due to the settings in project horizon. For some
> > reason, it was set to "Error", and this will prevent saving of
> > translation whenever this validation failed.
> >
> > You can change the setting via:
> > 
https://translate.openstack.org/project/view/horizon/settings/translation
> (need
> > to be project maintainer for admin), set the "Leading/trailing newline
> > (\n)" to warning.
> 
> Alex, that's a different behaviour according to the description:
> 
> Source
> 
> \n hello world with lead new line
> 
> 
> Target
> 
> missing \n hello world with lead new line
> 
> Nevertheless I changed the setting,
> Andreas
> 
> 
> >
> > ---------------------------------------------
> >
> > Alex Eng
> > Globalisation Tools Engineering
> > DID:+61 3514 8262 <callto:+61+3514+8262>
> > Mobile:+614 2335 3457 <callto:+614+2335+3457>
> >
> > Red Hat, Asia-Pacific Pty Ltd
> > Level 1, 193 North Quay
> > Brisbane 4000
> > Office:+61 7 3514 8100 <callto:+61+7+3514+8100>
> > Fax:+61 7 3514 8199 <callto:+61+7+3514+8199>
> > Website:www.redhat.com <http://www.redhat.com/>
> >
> > On Tue, Oct 6, 2015 at 4:59 AM, Andreas Jaeger <aj at suse.com
> > <mailto:aj at suse.com>> wrote:
> >
> >     Thanks for your comments and have a good night!
> >
> >         # Japanese team insert meaningless newlines to avoid warnings 
for
> >         Liberty translations
> >         # but would not like to do that in the future.
> >
> >
> >
> >     Please file a feature request with the Zanata team, I have not 
found
> >     an option to disable this myself ;(
> >
> >     Andreas
> >     --
> >       Andreas Jaeger aj@{suse.com <http://suse.com>,opensuse.org
> >     <http://opensuse.org>} Twitter/Identica: jaegerandi
> >        SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
> >         GF: Felix Imendörffer, Jane Smithard, Graham Norton,
> >             HRB 21284 (AG Nürnberg)
> >          GPG fingerprint = 93A3 365E CE47 B889 DF7F  FED1 389A 563C 
C272
> >     A126
> >
> >
> >     _______________________________________________
> >     Openstack-i18n mailing list
> >     Openstack-i18n at lists.openstack.org
> >     <mailto:Openstack-i18n at lists.openstack.org>
> >     http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-i18n
> >
> >
> >
> >
> > _______________________________________________
> > Openstack-i18n mailing list
> > Openstack-i18n at lists.openstack.org
> > http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-i18n
> >
> 
> 
> -- 
>   Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi
>    SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
>     GF: Felix Imendörffer, Jane Smithard, Graham Norton,
>         HRB 21284 (AG Nürnberg)
>      GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
> 
> 
> _______________________________________________
> Openstack-i18n mailing list
> Openstack-i18n at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-i18n
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-i18n/attachments/20151006/97041312/attachment.html>


More information about the Openstack-i18n mailing list