Translator cannot control word order of BatchAction message

Bug #1253678 reported by Akihiro Motoki
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
Fix Released
Low
Akihiro Motoki

Bug Description

Currently BatchAction message is generated by concatenating 'action' and 'data_type'.
In most cases 'action' is a verb and 'data_type' is an object.
If this is the only case translator can control the translation,
but in some action (such as TerminateInstance 'action')
is a combination of verb and object (e.g., "Scheduled termination of").
It is hard that translators find translated strings which covers both cases.

To address this, it is better to allow subclasses inheriting BatchAction
to specify a full action name containing '%(data_type)s' substitution
for action_present/action_past string. By doing so translators become
able to control the order of phrases completely.

Tags: i18n
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (master)

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

Changed in horizon:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to horizon (master)

Reviewed: https://review.openstack.org/57701
Committed: http://github.com/openstack/horizon/commit/0ef5c4701f75648843aa4daadc1bf69fc98731cf
Submitter: Jenkins
Branch: master

commit 0ef5c4701f75648843aa4daadc1bf69fc98731cf
Author: Akihiro MOTOKI <email address hidden>
Date: Thu Nov 21 07:01:10 2013 +0900

    Allow translators to control word order of BatchAction message

    Currently BatchAction message is generated by concatenating
    'action' and 'data_type'. In most cases 'action' is a verb
    and 'data_type' is an object. However in some action such as
    TerminateInstance 'action' is a combination of verb and
    object (e.g., "Scheduled termination of"). It is hard that
    translators find translated strings which covers both cases.

    This commit allows classes inheriting BatchAction to specify
    a full action name containing '%(data_type)s' substitution
    in action_present/ action_past so that translators can
    control the order of phrases completely.

    * _conjugate() in actions.py is renamed to _get_action_name()
      because this method no longer always conjugate words.
    * Changes action_past strings which are not a form of verb + obj
      to strings with "%(data_type)s"

    Closes-Bug: #1253678
    Change-Id: I3cf1dc74e22745eb3a9bd2edc3ec68ed389495b5

Changed in horizon:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in horizon:
milestone: none → icehouse-2
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in horizon:
milestone: icehouse-2 → 2014.1
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.