Bug 886718 - [ru_RU] Creating Organization: error message substitutes strings result in broken grammar
Summary: [ru_RU] Creating Organization: error message substitutes strings result in br...
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Content Management
Version: Nightly
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: Unspecified
Assignee: Miroslav Suchý
QA Contact: SAM QE List
URL:
Whiteboard:
: 886744 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-12-13 01:05 UTC by Yulia
Modified: 2019-09-26 16:29 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-19 18:14:13 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Yulia 2012-12-13 01:05:19 UTC
Description of problem:


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
Move cursor over the Administer menu at the top right corner and click on Manage Organizations OR Click Manage Organizations from the bottom of the organization menu list left tab next to Dashboard tab. (Perform the organization search: Type/Click on Filter... field from the organization list)
Click the + New Organization button.
Enter the name of the new organization in the Name field.
Leave Label EMPTY.
Hit Save.
  
Actual results:
Error message appears based on a following zanata string:
A label was not provided during %s creation; therefore, a label of '%s' was automatically assigned. If you would like a different label, please delete the %s and recreate it with the desired label.

%s is replaced with word "Organization" in this particular example (not the actual name of the organization). The grammar case of nouns in Russian will be different. Therefore resulting paragraph 's grammar is incorrect.


Expected results:

Suggestion: replace %s with word "Organization" in source paragraph, or use the name of the organization as a replacement

Additional info:

Comment 1 Tom McKay 2012-12-18 14:24:19 UTC
Mass move of i18n to CFSE where they are present as well

Comment 3 Miroslav Suchý 2013-02-12 12:04:48 UTC
Please suggest better wording for source string, which can be translatable to Russian.
Otherwise, I'm affraid, this will be closed as WONTFIX.

Comment 4 Yulia 2013-02-13 00:23:30 UTC
May be: 

A label was not provided during organization creation; therefore, a label of '%s' was automatically assigned. If you would like a different label, please delete the organization and recreate it with the desired label.

That way the word "organization" is included into source paragraph instead replacing %s. That will allow translators adjust the grammar accordingly.

Thanks for looking into this,
Yulia

Comment 5 Miroslav Suchý 2013-02-13 08:45:56 UTC
*** Bug 886744 has been marked as a duplicate of this bug. ***

Comment 6 Miroslav Suchý 2013-02-13 08:49:44 UTC
I will copy https://bugzilla.redhat.com/show_bug.cgi?id=886744#c5 here:

The code is:
    label_assigned_text = _("A label was not provided during %s creation; therefore, a label of '%s' was " +
                            "automatically assigned. If you would like a different label, please delete the " +
                            "%s and recreate it with the desired label.") % [object_type, label, object_type]

so first and third parametr is the same.
Object_type can be e.g. repository, environment, organization, product etc.
Hardcoding first %s is not possible (or will lead to duplication of strings).

I would say that having both object_type and label in message is MUST item. And if necessary I would prefer less gramatical correct translations, but with both values as it gives admin necessary information.
If you came with translation which preserve all variable, that would be great.

Comment 7 Hedda Peters 2013-02-13 23:16:45 UTC
Hi Miroslav,
I discussed this issue with Yulia and we can see two possible solutions:

1) Hardcoding the first and third variables (object_type) and having duplicate strings accordingly. From a translators point of view I'd much rather translate 10 strings correct than 1 string knowingly incorrect. 

2) Re-writing the string something like this: 
"No label was provided. Object type: %s. A label of '%s' was automatically assigned. If you would like a different label, delete the object (object type: %s) and recreate it with the desired label."
Sounds not as polished, but is possible to be translated correctly for any object type. 

BTW, this issue has been reported for de-DE and ru-RU, but I suspect more languages might be affected - all those that use different grammatical genders for nouns. Worth trying to find a solution for.

Comment 8 Miroslav Suchý 2013-02-14 14:24:36 UTC
The 2) is maybe grammatically correct but ugly as hell. So I went the 1) way. Even if that result in ugly code.

https://github.com/Katello/katello/pull/1594

Comment 9 Mike McCune 2013-09-19 18:14:13 UTC
These bugs have been resolved in upstream projects for a period of months so I'm mass-closing them as CLOSED:UPSTREAM.  If this is a mistake feel free to re-open.


Note You need to log in before you can comment on or make changes to this bug.