After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 308363 - non-translator-friendly strings in mozillasource.py and storage.py
non-translator-friendly strings in mozillasource.py and storage.py
Status: RESOLVED FIXED
Product: sabayon
Classification: Deprecated
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: John Dennis
John Dennis
Depends on:
Blocks:
 
 
Reported: 2005-06-20 07:08 UTC by Funda Wang
Modified: 2005-08-01 09:47 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Funda Wang 2005-06-20 07:08:53 UTC
There are following two strings in sabayon.pot:

#: ../lib/sources/mozillasource.py:855
#, python-format
msgid "duplicate name(%s) in section %s"

#: ../lib/storage.py:625 ../lib/storage.py:636
#, python-format
msgid "'%s' does not exist in profile revision '%s'"

It is likely that the translators need to adjust the order of different 
placeholders in some languages. But according to python-format defination[1], we 
cannot simply use "%2$s" form of placeholders, but that we must know the name of 
the variable exactly, i.e. "%(key_name)s".

So, I would suggest that the maintainers should put the name of the variables 
inside code. That is:

    msgid "duplicate name(%(pair_name)s) in section %(section_name)s"

[1]: http://www.gnu.org/software/gettext/manual/html_node/gettext_199.html
Comment 1 Mark McLoughlin 2005-06-20 08:08:54 UTC
Sounds reasonable
Comment 2 Mark McLoughlin 2005-07-29 16:22:27 UTC
Thanks, fixed now.

It occurred to me, though, that you could add the variable names yourself to the
translated string even if it wasn't in the original string. I do agree, though,
that it would be better to have them in the original strings too.


2005-07-29  Mark McLoughlin  <markmc@redhat.com>

        Fixes bug #308363

        * lib/sources/mozillasource.py,
          lib/storage.py: add variable names to some
        format strings so translators can switch around
        their order.

Comment 3 Funda Wang 2005-07-31 08:07:28 UTC
#: ../lib/storage.py:612
#, python-format
msgid "'%s' does not exist in profile revision '%s'"

It hasn't been fixed yet now.
Comment 4 Mark McLoughlin 2005-08-01 09:47:05 UTC
Thanks, it was another instance of the same string:

2005-08-01  Mark McLoughlin  <markmc@redhat.com>

        * lib/storage.py: fix another instance of
        a translator-unfriendly string. Bug #308363