openerp-india team mailing list archive
-
openerp-india team
-
Mailing list archive
-
Message #09763
[Bug 971412] [NEW] Translations export has no fixed order
Public bug reported:
1- export a .po using the Administration > Translations > Import/Export, export a file for a module,
2- add some fields on any object of the module:
'test_translation': fields.boolean('Test translation'),
'test_translation2': fields.boolean('Test translation2'),
for example
3- reexport the .po exported in step 1
You will get 2 files containing the same data (with the exception of the
new fields to translate) BUT in a totally different order making the
difference between this two files enormous while just one line should
have changed...
This is only because of the use of dictionnary in the export function
and the fact that dictionnaries' keys are not sorted in python:
changing only some lines from:
for src, row in grouped_rows.items():
to:
for src in sorted(grouped_rows):
row = grouped_rows[src]
makes sure the translation are always exported in the same order making
the historization of the translations way easier/clearer.
** Affects: openobject-server
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Server.
https://bugs.launchpad.net/bugs/971412
Title:
Translations export has no fixed order
Status in OpenERP Server:
New
Bug description:
1- export a .po using the Administration > Translations > Import/Export, export a file for a module,
2- add some fields on any object of the module:
'test_translation': fields.boolean('Test translation'),
'test_translation2': fields.boolean('Test translation2'),
for example
3- reexport the .po exported in step 1
You will get 2 files containing the same data (with the exception of
the new fields to translate) BUT in a totally different order making
the difference between this two files enormous while just one line
should have changed...
This is only because of the use of dictionnary in the export function
and the fact that dictionnaries' keys are not sorted in python:
changing only some lines from:
for src, row in grouped_rows.items():
to:
for src in sorted(grouped_rows):
row = grouped_rows[src]
makes sure the translation are always exported in the same order
making the historization of the translations way easier/clearer.
To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/971412/+subscriptions
Follow ups
-
[Bug 971412] Re: Translations export has no fixed order
From: Launchpad Bug Tracker, 2012-11-06
-
[Bug 971412] Re: Translations export has no fixed order
From: Amit Parik (OpenERP), 2012-11-01
-
[Bug 971412] Re: Translations export has no fixed order
From: Xavier Fernandez http://www.smile.fr, 2012-10-31
-
[Bug 971412] Re: Translations export has no fixed order
From: Ravi Gohil (OpenERP), 2012-10-31
-
[Bug 971412] Re: Translations export has no fixed order
From: Ravi Gohil (OpenERP), 2012-10-31
-
[Bug 971412] Re: Translations export has no fixed order
From: Ravi Gohil (OpenERP), 2012-10-31
-
[Bug 971412] Re: Translations export has no fixed order
From: Vinay Rana (openerp), 2012-10-31
-
[Bug 971412] Re: Translations export has no fixed order
From: Numérigraphe, 2012-10-15
-
[Bug 971412] Re: Translations export has no fixed order
From: Vinay Rana (openerp), 2012-10-11
-
[Bug 971412] Re: Translations export has no fixed order
From: Numérigraphe, 2012-05-11
-
[Bug 971412] Re: Translations export has no fixed order
From: Jignesh Rathod(OpenERP), 2012-04-12
-
[Bug 971412] Re: Translations export has no fixed order
From: Xavier Fernandez http://www.smile.fr, 2012-04-10
-
[Bug 971412] Re: Translations export has no fixed order
From: Vishal Parmar(Open ERP), 2012-04-03
-
[Bug 971412] Re: Translations export has no fixed order
From: Xavier Fernandez http://www.smile.fr, 2012-04-02
-
[Bug 971412] [NEW] Translations export has no fixed order
From: Xavier Fernandez http://www.smile.fr, 2012-04-02
References