i18n issue: each project needs to have an individual domain name

Bug #1076285 reported by Vincent Hou
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
Mark McLoughlin
oslo-incubator
Fix Released
Medium
Mark McLoughlin

Bug Description

In openstack.common.gettextutils.py, gettext.translation for each openstack project should be different, since each project has one specific name. For example, nova has the domain name of nova, cinder has the domain name of cinder, etc. 'openstack-common' is not able to work for all the projects.

Tags: i18n
Mark McLoughlin (markmc)
affects: openstack-common → oslo
Mark McLoughlin (markmc)
Changed in oslo:
status: New → Confirmed
importance: Undecided → Medium
tags: added: i18n
Changed in oslo:
assignee: nobody → Ying Chun Guo (daisy-ycguo)
Revision history for this message
Ying Chun Guo (daisy-ycguo) wrote :

The problem is changed to how to get the correct "domain name" in commons.

I have two options:
1, get the domain name from a configuration parameter in the config file.
2, deduce the domain name from the real file path of "gettextutils.py" after copying into each separate project.

Which one is better? Let me know your opinion.

Regards
Daisy

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to oslo-incubator (master)

Fix proposed to branch: master
Review: https://review.openstack.org/25266

Changed in oslo:
assignee: Ying Chun Guo (daisy-ycguo) → Mark McLoughlin (markmc)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo-incubator (master)

Reviewed: https://review.openstack.org/25266
Committed: http://github.com/openstack/oslo-incubator/commit/f75126c69af42a7b714890f66df4cd1f4857b68b
Submitter: Jenkins
Branch: master

commit f75126c69af42a7b714890f66df4cd1f4857b68b
Author: Mark McLoughlin <email address hidden>
Date: Mon Mar 25 07:47:21 2013 +0000

    gettextutils: fix translation domain

    Fixes bug #1076285

    When oslo-incubator code gets copied into a project, the project's
    l10n infrastructure will extract translatable messages from the
    oslo code into the project's message catalog. Translations of those
    messages will not be found if we use 'openstack.common' as the
    translation domain.

    Instead, use 'oslo' as the translation domain and update.py will
    change this to the project name.

    Change-Id: I7ab46c4f860c9c307758ab63002ae410e4f975fe

Changed in oslo:
status: In Progress → Fix Committed
Mark McLoughlin (markmc)
Changed in nova:
status: New → Fix Committed
importance: Undecided → Medium
assignee: nobody → Mark McLoughlin (markmc)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/25822
Committed: http://github.com/openstack/nova/commit/c51321ce9703dacea710e2afeb0281cb16c25341
Submitter: Jenkins
Branch: master

commit c51321ce9703dacea710e2afeb0281cb16c25341
Author: Mark McLoughlin <email address hidden>
Date: Mon Apr 1 01:37:34 2013 +0100

    Sync latest gettextutils from oslo-incubator

    Fixes bug #1076285

    Ensure translations for strings under nova.openstack.common are
    translated using the 'nova' translation domain rather than the
    non-existent 'openstack-common' translation domain.

    Change-Id: I6aee3061cbffd3bf940f1881e8540cd996d0b12a

Thierry Carrez (ttx)
Changed in nova:
milestone: none → havana-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in oslo:
milestone: none → havana-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in oslo:
milestone: havana-1 → 2013.2
Thierry Carrez (ttx)
Changed in nova:
milestone: havana-1 → 2013.2
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.