You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Bruno Busco (JIRA)" <ji...@apache.org> on 2008/03/08 00:33:46 UTC

[jira] Created: (OFBIZ-1698) Locale labels in language dirrerent from the fallback sometime are not displayed

Locale labels in language dirrerent from the fallback sometime are not displayed
--------------------------------------------------------------------------------

                 Key: OFBIZ-1698
                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
             Project: OFBiz
          Issue Type: Bug
          Components: framework
    Affects Versions: SVN trunk
            Reporter: Bruno Busco


A label is not displayed in the selected language but in the fallback one when ALL the following are true:
- A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
- The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
- The screen includes first File1UiLabels.xml and then File2UiLabels.xml
- In File1UiLabels.xml there is NO translation for the selected language
- In File2UiLabels.xml there is the translation for the selected language

This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.

In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Re: [jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by Jacques Le Roux <ja...@les7arts.com>.
Ok, thanks !

Jacques

From: "Bruno Busco" <br...@gmail.com>
> Thank you, Jacques.
> When you will be on the issue, if you want, I will run the script again on
> the latest trunk to simplify the commit.
> Just let me know.
>
> -Bruno
>
>
> 2008/4/12, Jacques Le Roux (JIRA) <ji...@apache.org>:
>>
>>
>>     [
>> https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588239#action_12588239]
>>
>> Jacques Le Roux commented on OFBIZ-1698:
>> ----------------------------------------
>>
>> Bruno,
>>
>> Did not find the time yet this weekend, but I do not forget...
>>
>> > Locale labels in language different from the fallback sometime are not
>> displayed
>> >
>> --------------------------------------------------------------------------------
>> >
>> >                 Key: OFBIZ-1698
>> >                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>> >             Project: OFBiz
>> >          Issue Type: Bug
>> >          Components: framework
>> >    Affects Versions: SVN trunk
>> >            Reporter: Bruno Busco
>> >            Assignee: Jacques Le Roux
>> >         Attachments: cleanlabels.patch.zip
>> >
>> >
>> > A label is not displayed in the selected language but in the fallback
>> one when ALL the following are true:
>> > - A language different from the one specified as
>> "locale.properties.fallback" in framework/common/config/general.properties
>> is selected
>> > - The label is defined in more than one XXXUiLabels.XML file (say
>> File1UiLabels.xml and File2UiLabels.xml)
>> > - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
>> > - In File1UiLabels.xml there is NO translation for the selected language
>> > - In File2UiLabels.xml there is the translation for the selected
>> language
>> > This bug was not present in Release 4.0 and i think could have been
>> introduced with the new locale system.
>> > You can check the bug going in the trunk demo in the ecommerce main page
>> and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not
>> translated.
>> > In the R4.0 demo it is all OK
>>
>> --
>> This message is automatically generated by JIRA.
>> -
>> You can reply to this email to add a comment to the issue online.
>>
>>
> 


Re: [jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by Bruno Busco <br...@gmail.com>.
Thank you, Jacques.
When you will be on the issue, if you want, I will run the script again on
the latest trunk to simplify the commit.
Just let me know.

-Bruno


2008/4/12, Jacques Le Roux (JIRA) <ji...@apache.org>:
>
>
>     [
> https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588239#action_12588239]
>
> Jacques Le Roux commented on OFBIZ-1698:
> ----------------------------------------
>
> Bruno,
>
> Did not find the time yet this weekend, but I do not forget...
>
> > Locale labels in language different from the fallback sometime are not
> displayed
> >
> --------------------------------------------------------------------------------
> >
> >                 Key: OFBIZ-1698
> >                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
> >             Project: OFBiz
> >          Issue Type: Bug
> >          Components: framework
> >    Affects Versions: SVN trunk
> >            Reporter: Bruno Busco
> >            Assignee: Jacques Le Roux
> >         Attachments: cleanlabels.patch.zip
> >
> >
> > A label is not displayed in the selected language but in the fallback
> one when ALL the following are true:
> > - A language different from the one specified as
> "locale.properties.fallback" in framework/common/config/general.properties
> is selected
> > - The label is defined in more than one XXXUiLabels.XML file (say
> File1UiLabels.xml and File2UiLabels.xml)
> > - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> > - In File1UiLabels.xml there is NO translation for the selected language
> > - In File2UiLabels.xml there is the translation for the selected
> language
> > This bug was not present in Release 4.0 and i think could have been
> introduced with the new locale system.
> > You can check the bug going in the trunk demo in the ecommerce main page
> and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not
> translated.
> > In the R4.0 demo it is all OK
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>

[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12576797#action_12576797 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

These are good question, answers will complete http://docs.ofbiz.org/display/OFBIZ/Tips+for+translation. We really need to resolve all ambiguities...

I'm not sure for the 1st point. The reason is that Order is one of the "core" applications (applications which other, like eCommerce, humanres or apps in specialpurpose, hot deploy use as fundamental bricks). Hence it should be independent of any "upper" applications (like eCommerce). On the other hands, the labels is obviously an eCommerce one. History is certainly the reason, we need an expert here, :o)

For EcommerceCartSummary, from my POV I will renanme it OrderCartSummary (eveyrwhere) and delete EcommerceCartSummary  from eCommerce labels.

2d point : yes, I already asked myslef the same question, not sure of an answer though. I would say : yes.

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12579058#action_12579058 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Interesting I will have a look as soon as possible... BTW which version of python did you use (I will do it in on Windows, I will have to update), thanks

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.py
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12579059#action_12579059 ] 

Bruno Busco commented on OFBIZ-1698:
------------------------------------

I use windows as well (XP). I have installed ActivePython 2.4.3 but should work with other versions also.

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.py
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12621860#action_12621860 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Just a reminder about this (for myself mostly it seems ;o) : when there are no labels for a language it's not defaulting to en

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12581154#action_12581154 ] 

Bruno Busco commented on OFBIZ-1698:
------------------------------------

If we agree with the following dependence hierarchy i can run the script against the last trunk and submit a patch with all the modified UiLabels files.

============================================
"framework/common/config/CommonUiLabels.xml",
"framework/common/config/PrefErrorUiLabels.xml",
"framework/common/config/SecurityextUiLabels.xml",
"framework/service/config/ServiceErrorUiLabels.xml",
"framework/minilang/config/MiniLangErrorUiLabels.xml",
"framework/shark/config/SharkUILabels.xml",
"framework/guiapp/config/XuiUiLabels.xml",
"framework/example/config/ExampleUiLabels.xml",
"framework/webapp/config/WebappUiLabels.xml",
"framework/webtools/config/WebtoolsErrorUiLabels.xml",
"framework/webtools/config/WebtoolsUiLabels.xml",
"applications/accounting/config/AccountingUiLabels.xml",
"applications/party/config/PartyUiLabels.xml",
"applications/product/config/ProductErrorUiLabels.xml",
"applications/product/config/ProductUiLabels.xml",
"applications/order/config/OrderErrorUiLabels.xml",
"applications/order/config/OrderUiLabels.xml",
"applications/content/config/ContentUiLabels.xml",
"applications/content/config/ContentErrorUiLabels.xml",
"applications/ecommerce/config/EcommerceUiLabels.xml",
"applications/manufacturing/config/ManufacturingReportsUiLabels.xml",
"applications/manufacturing/config/ManufacturingUiLabels.xml",
"applications/marketing/config/MarketingUiLabels.xml",
"applications/humanres/config/HumanResUiLabels.xml",
"applications/workeffort/config/WorkEffortUiLabels.xml",
"specialpurpose/assetmaint/config/AssetMaintUiLabels.xml",
"specialpurpose/bi/config/BiUiLabels.xml",
"specialpurpose/ebay/config/EbayUiLabels.xml",
"specialpurpose/googlebase/config/GoogleBaseUiLabels.xml",
"specialpurpose/oagis/config/OagisUiLabels.xml",
"specialpurpose/ProjectMgr/config/ProjectMgrUiLabels.xml",
============================================


> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.py
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12581263#action_12581263 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Hi Bruno,

I did not find enough time to seriously look at your python script. About the order above, I can't see any problems with it though for instance I don't think any modules depend of Shark and Xui at this stage and I would put Ecommerce after "core all core applications" (like manufacturing, workeffort and marketing). Anyway, it's a matter of taste I guess as soon as an order is given and respected. But please wait before we find a consensus. I will ask the dev ML.

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.py
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12621866#action_12621866 ] 

Adrian Crum commented on OFBIZ-1698:
------------------------------------

Jacques,

If you provide an example of where this is occurring, I will take a look at it.


> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12611062#action_12611062 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Bruno,

Something is not clear to me. Your script says :

  Duplication of label CommonDescription found in applications/product/config/ProductUiLabels.xml (7 languages)
    Label removed from file applications/product/config/ProductUiLabels.xml

But the label is only moved (sorted) in the file not removed. Is that normal ? Are you sure of that "Number of removed labels   : 636" ?
BTW, if we want to remove them we should at least check that a such label exists in the right file (here common) and that in this right file there are not less languagues and that existing values are the same. Else I suggest to write something (both labels)  to allow to do it manually later, rather than removing it automatically. It takes a man to do errors, but it takes a machine to really screw it up ;o)

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12578157#action_12578157 ] 

Bruno Busco commented on OFBIZ-1698:
------------------------------------

Oh yes it will be a long, not very exiting but simple work. Since I need to touch some UiLabels files to add italian translations i could start with this also.
All we need is to agree with an application dependence hierarchy (if someone has this clear in mind could post it here otherwise i will try to work out a my proposal) and starting applying the rule on any new label added to OFBiz.
The work is not necessarly to be done at once.

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12621881#action_12621881 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Adrian,

I have 2, please look at revisions 685140 and 684522




> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12577752#action_12577752 ] 

Bruno Busco commented on OFBIZ-1698:
------------------------------------

Still checking for UiLabels definition redundancy. I can report two examples found:

Label: AccountingAccountNumber
Defined in: AccountingUiLabels.xml (10 languages), EcommerceUiLabels.xml (14 languages), OrderUiLabels.xml (4 languages)
Used in: ecommerce, order, party [and NOT in accounting :( ]

Label: AccountingBillingAccount
Defined in: AccountingUiLabels.xml (10 languages), EcommerceUiLabels.xml (13 langiages), OrderUiLabels.xml (4 languages), PartyUiLabels.xml (10 languages)
Used in: accounting, ecommerce, order, party

I think i have found a generic rule that we could follow, here it is, please review it.

1) Define a dependence hierarchy among applications (even between core applications). If two applications are at the same level (i.e. depends each other, one must be declared at an higher level in the hierarchy) (higher level means that the application is more dependent from others)

2) If a label is used in more than one application it should be defined ONLY in the lower level application UiLabels file.

3) All labels defined in a AppNameUiLabels.xml files MUST be named AppNameLabelName

What do you think about? Does this make sense?

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12625198#action_12625198 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Moreover, this bug seems to be random...
The only way for now is to put all languages needed, even if it's the same sentence than in English
Actually French is the most, and maybe sole, concerned and only for few words. So it's not a big deal... We will only have to put them as they appears...

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12578076#action_12578076 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

This sounds good to me (I can't see any flaws in this proposition), but it means a lot of work moving and deleting labels, isn'it ? Of course, I would prefer to have this cleaned. I only wonder if we will have ever enough will to do it ;o) Though I saw the work you already did ! Moreover I would prefer to have other opinions.

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12576797#action_12576797 ] 

jacques.le.roux edited comment on OFBIZ-1698 at 3/9/08 11:00 AM:
-----------------------------------------------------------------

These are good question, answers will complete http://docs.ofbiz.org/display/OFBIZ/Tips+for+translation. We really need to resolve all ambiguities...

I'm not sure for the 1st point. The reason is that Order is one of the "core" applications (applications which other, like eCommerce, humanres or apps in specialpurpose/hot deploy use as fundamental bricks). Hence it should be independent of any "upper" applications (like eCommerce). On the other hands, the labels is obviously an eCommerce one. History is certainly the reason, we need an expert here, :o)

For EcommerceCartSummary, from my POV I will renanme it OrderCartSummary (eveyrwhere) and delete EcommerceCartSummary  from eCommerce labels.

2d point : yes, I already asked myslef the same question, not sure of an answer though. I would say : yes.

      was (Author: jacques.le.roux):
    These are good question, answers will complete http://docs.ofbiz.org/display/OFBIZ/Tips+for+translation. We really need to resolve all ambiguities...

I'm not sure for the 1st point. The reason is that Order is one of the "core" applications (applications which other, like eCommerce, humanres or apps in specialpurpose, hot deploy use as fundamental bricks). Hence it should be independent of any "upper" applications (like eCommerce). On the other hands, the labels is obviously an eCommerce one. History is certainly the reason, we need an expert here, :o)

For EcommerceCartSummary, from my POV I will renanme it OrderCartSummary (eveyrwhere) and delete EcommerceCartSummary  from eCommerce labels.

2d point : yes, I already asked myslef the same question, not sure of an answer though. I would say : yes.
  
> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-1698:
-------------------------------

    Attachment:     (was: cleanlabels.py)

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588239#action_12588239 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Bruno,

Did not find the time yet this weekend, but I do not forget...

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12576582#action_12576582 ] 

Adrian Crum commented on OFBIZ-1698:
------------------------------------

I spent some time checking into this and it appears to me the system is working correctly even though the result seems wrong.

The UI labels are loaded in the eCommerce CommonScreens.xml file as follows:

<property-map resource="EcommerceUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="ContentUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="ProductUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="AccountingUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="PartyUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="OrderUiLabels" map-name="uiLabelMap" global="true"/>

The framework searches for the UI label in sequence from the top down, so EcommerceUiLabels is checked first. If the user's locale is italian, the framework will search for a matching italian label. If that isn't found, it searches for a matching english label. If that isn't found, it moves on to the ContentUiLabels properties file and the process repeats.

In the example you gave, the EcommerceCartSummary UI label exists in the EcommerceUiLabels file, but there is no translation for italian. Since a translation exists for english, that one is used. Since a matching label is found, the process stops - so the italian translation in the OrderUiLabels properties file is never found.

The solution is to include the italian translation in the EcommerceUiLabels properties file.


> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-1698:
-------------------------------

    Attachment: cleanlabels.py

Jacques,
i have written the python script attached (cleanlabels.py) that does a complete scan of the specified files for label duplication.

If a duplication is found it merges all new languages eventually found and then deletes the label duplications.
To use the script simply copy it in the ofbiz root folder and run it.

I have made some assumption regarding the file dependencies (you can check the labelFileList variable.
The dependency can be changed by simply swapping the file names in the list. The upper files are the most "fundamental" files and then mode dependent ones come.

I have run the script against my ofbiz trunk rev.636622 and 888 duplicated labels have been removed.
This is the report i get from the script.
=====================================
Number of processed files  : 31
Number of processed labels : 9003
Number of removed labels   : 888
=====================================

Using the changed label files all labels are now displayed correctly in italian becouse no duplication is found and the languages have been merged.

A thing that should be still done on the xml files after the script execution is a sort for languages becouse during merge the new languages are simply added at the bottom of languages list (i have not found a way to easily sort it).

I hope this script will be usefull.

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.py
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacques Le Roux closed OFBIZ-1698.
----------------------------------

    Resolution: Fixed
      Assignee: Adrian Crum  (was: Jacques Le Roux)

Seems ok so far, thanks Adrian

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Adrian Crum
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12610689#action_12610689 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Hi Bruno,

Please let me know if you are still interested by this issue (I already asked on dev ML). I gave it a try today. After a 1st review, here are some remarks

There are some annoyances :

========================================================================================
Trivial (but maybe not in you Python script)
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    
+<?xml version="1.0" encoding="UTF-8" ?><!--

--->
-<resource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+--><resource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">


========================================================================================
.&quot; and at large all special characters are replaced by HTML entities (not easy to learn and maintain)
-        <value xml:lang="nl">Berekenings eigenschappen voor de boekhouddiensten zijn niet geconfigureerd, processen is gestopt."</value>
+        <value xml:lang="nl">Berekenings eigenschappen voor de boekhouddiensten zijn niet geconfigureerd, processen is gestopt.&quot;</value>


========================================================================================
Because your algorithm was written before we decided to not have overriden labels in different files, we have some in this patch. If you are still interested you could change your script to only keep CommonDescription in Common file in the case below. At large, the rule should be discussed before. But in case of duplicated lables, we may automatically keep only labels within their own file (like CommonDescription). Your script may in other cases write a list of possible changes to check by hand, ie 2 patches : 1 for changes to apply, one for changes to check before applying.
ContentUiLabels.xml
+    <property key="CommonDescription">
+        <value xml:lang="ar">وصف</value>
+        <value xml:lang="en">Description</value>
+        <value xml:lang="it">Descrizione</value>
+        <value xml:lang="ro">Descriere</value>
+        <value xml:lang="th">รายละเอียด</value>
+        <value xml:lang="zh">描述</value>
+    </property>

-    <property key="CommonDescription">
-        <value xml:lang="ar">وصف</value>
-        <value xml:lang="en">Description</value>
-        <value xml:lang="it">Descrizione</value>
-        <value xml:lang="ro">Descriere</value>
-        <value xml:lang="th">รายละเอียด</value>
-        <value xml:lang="zh">描述</value>
-    </property>


ProductUiLabels.xml
+    <property key="CommonDescription">
+        <value xml:lang="en">Description</value>
+        <value xml:lang="fr">Description</value>
+        <value xml:lang="it">Descrizione</value>
+        <value xml:lang="ro">Descriere</value>
+        <value xml:lang="ru">Описание</value>
+        <value xml:lang="th">อธิบาย</value>
+        <value xml:lang="zh">描述</value>
+    </property>

-    <property key="CommonDescription">
-        <value xml:lang="en">Description</value>
-        <value xml:lang="fr">Description</value>
-        <value xml:lang="it">Descrizione</value>
-        <value xml:lang="ro">Descriere</value>
-        <value xml:lang="ru">Описание</value>
-        <value xml:lang="th">อธิบาย</value>
-        <value xml:lang="zh">描述</value>
-    </property>

CommonUiLabels.xml
    <property key="CommonDescription">
        <value xml:lang="ar">وصف</value>
        <value xml:lang="cs">Popis</value>
        <value xml:lang="de">Beschreibung</value>
        <value xml:lang="en">Description</value>
        <value xml:lang="es">Descripción</value>
        <value xml:lang="fr">Description</value>
        <value xml:lang="it">Descrizione</value>
        <value xml:lang="nl">Omschrijving</value>
        <value xml:lang="pt">Descrição</value>
        <value xml:lang="ro">Descriere</value>
        <value xml:lang="ru">Описание</value>
        <value xml:lang="th">คำอธิบาย</value>
        <value xml:lang="zh">描述</value>
        <value xml:lang="zh_CN">描述</value>
    </property>


Please, let me know what you think.

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-1698:
-------------------------------

    Summary: Locale labels in language different from the fallback sometime are not displayed  (was: Locale labels in language dirrerent from the fallback sometime are not displayed)

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12611210#action_12611210 ] 

Bruno Busco commented on OFBIZ-1698:
------------------------------------

Jacques,
you are right there is something not working in the script. It SHOULD delete the label but it fails to do it. At the moment I cannot fix it, I will fix it asap.
Sorry,
Bruno

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-1698:
-------------------------------

    Attachment: cleanlabels_1.zip

Jacques,
yes I am still interesting in this issue.

In the attached file "cleanlabels_1.zip" I have included a new version of the script which now scans some new added UiLabels files and fixes the &quot; problem.

The problem on the file header I did not manage to fix it and so I changed the files manually.

I have run the script on the latest trunk and included the patch in the zip file.

About your suggestion about moving automatically the labels in the proper file looking at the name I do not have time to implement it but I think it is better to commit this patch that removes all the duplications (636 have been found and rempved).

Then without duplications the moving of the labels will be simpler and could also be done manually.


> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacques Le Roux reassigned OFBIZ-1698:
--------------------------------------

    Assignee: Jacques Le Roux

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12610924#action_12610924 ] 

Jacques Le Roux commented on OFBIZ-1698:
----------------------------------------

Thanks for update Bruno,

I think you are right. I will commit your results, after a quick check

> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-1698:
-------------------------------

    Attachment: cleanlabels.patch.zip

Hi Jacques,
i have updated the script with your suggestion about the files hierarchy and have attached the cleanlabels.patch.zip that includes the (large) patch, the updated script that has been used and the script report file.

According to the script report the patch removes 887 redundant label definitions.

Of course a deep test must be done to be sure that all labels are still found.


> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12634159#action_12634159 ] 

Adrian Crum commented on OFBIZ-1698:
------------------------------------

Jacques,

I believe the problem was fixed in rev 698429. Can we close this now?


> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>         Attachments: cleanlabels.patch.zip, cleanlabels_1.zip
>
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1698) Locale labels in language different from the fallback sometime are not displayed

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12576776#action_12576776 ] 

Bruno Busco commented on OFBIZ-1698:
------------------------------------

Thank you for having checked this.
Now, since the EcommerceCartSummary definition is the same in both EcommerceUiLabels and OrderUiLabels files (for the defined languages) what do you think about the alternative solution of moving the definition in EcommerceUiLabels, merging all the languages and deleteing the definition from OrderUiLabels ?
The label name starts with "Ecommerce" so i think that EcommerceUiLabels.xml is the right place for it.

This will reduce redundancy, will work with the logic you have explained and will make OFBiz cleaner (IMHO).

One more thing: 
According to the logic that in the list should be located FIRST more specific files and then more generic, shouldn't CommonUiLabels be the LAST in the list?


> Locale labels in language different from the fallback sometime are not displayed
> --------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1698
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1698
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Bruno Busco
>            Assignee: Jacques Le Roux
>
> A label is not displayed in the selected language but in the fallback one when ALL the following are true:
> - A language different from the one specified as "locale.properties.fallback" in framework/common/config/general.properties is selected
> - The label is defined in more than one XXXUiLabels.XML file (say File1UiLabels.xml and File2UiLabels.xml)
> - The screen includes first File1UiLabels.xml and then File2UiLabels.xml
> - In File1UiLabels.xml there is NO translation for the selected language
> - In File2UiLabels.xml there is the translation for the selected language
> This bug was not present in Release 4.0 and i think could have been introduced with the new locale system.
> You can check the bug going in the trunk demo in the ecommerce main page and selecting italian. -> Labels "Cart Summary" and "Special Offers" are not translated.
> In the R4.0 demo it is all OK

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.