GNOME Bugzilla – Bug 720707
New strings partly not traslatable
Last modified: 2013-12-20 17:44:27 UTC
Created attachment 264506 [details] [review] Patch separating, solving truncated strings The newly added file <folks>/backends/bluez/bluez-persona-store.vala has some strings that were not correctly parsed by xgettext and these strings are trucanted in the PO files. As consequence, PO files have only part of these strings and translators will translated incorrectly (which is pretty much bad). There is a patch attached to this report. But, For example, The following string in bluez-persona-store.vala [1] ... _("Error during transfer of the address book ‘%s’ from " + + "Bluetooth device ‘%s’."), ... generates a POT file [2] (as well as PO file for each language) with the following source string (msgind): #. Translators: the first parameter is the name of the failed #. * transfer, and the second is a Bluetooth device alias. #. Translators: the first parameter is the name of the #. * failed transfer, the second is a Bluetooth device #. * alias, and the third is an error message. #: ../backends/bluez/bluez-persona-store.vala:569 #: ../backends/bluez/bluez-persona-store.vala:584 #, c-format msgid "Error during transfer of the address book ‘%s’ from " msgstr "" [1] https://git.gnome.org/browse/folks/tree/backends/bluez/bluez-persona-store.vala [2] https://l10n.gnome.org/POT/folks.master/folks.master.pot
Correction: file <folks>/backends/bluez/bluez-persona.vala has problems as well, already fixed in the patch. ps.: this issue was introduced in this commit: https://git.gnome.org/browse/folks/commit/?id=659a5c4539912bb3b31f7e55e48e6fd4215257f8
Created attachment 264617 [details] [review] bluez: Fix translatable strings spanning multiple lines gettext versions older than 0.18.3 don’t support multi-line translatable strings in Vala source code. Rather than bumping the gettext version, don’t split the strings. In future, the gettext dependency can be bumped to 0.18.3 and the strings can be line-wrapped again.
(In reply to comment #0) > The newly added file <folks>/backends/bluez/bluez-persona-store.vala has some > strings that were not correctly parsed by xgettext and these strings are > trucanted in the PO files. As consequence, PO files have only part of these > strings and translators will translated incorrectly (which is pretty much bad). This is a bug in versions of gettext older than 0.18.3 (the latest release). With 0.18.3 it works fine for me, but it’s a bit unreasonable to expect all the translators to upgrade gettext just for libfolks. I’ve pushed a slightly modified version of your patch, which should fix the problem. Thanks a lot for the bug report and patch! commit 983bb285a223f834092a21098801c850cf9b256a Author: Rafael Ferreira <rafael.f.f1@gmail.com> Date: Fri Dec 20 14:42:26 2013 +0000 bluez: Fix translatable strings spanning multiple lines gettext versions older than 0.18.3 don’t support multi-line translatable strings in Vala source code. Rather than bumping the gettext version, don’t split the strings. In future, the gettext dependency can be bumped to 0.18.3 and the strings can be line-wrapped again. https://bugzilla.gnome.org/show_bug.cgi?id=720707 NEWS | 1 + backends/bluez/bluez-backend.vala | 8 ++------ backends/bluez/bluez-persona-store.vala | 25 +++++++++++-------------- 3 files changed, 14 insertions(+), 20 deletions(-)
I found the same issue, but in another file: <folks>/backends/ofono/ofono-backend.vala POT file has: #: ../backends/ofono/ofono-backend.vala:193 msgid "No oFono object manager running, so the oFono " msgstr "" ... while the source file has throw new DBusError.SERVICE_UNKNOWN ( _("No oFono object manager running, so the oFono " + "backend will be inactive. Either oFono isn’t installed " + "or the service can’t be started.")); Should I file a new bug, or can we fix it in here ? ps.: I'm out of Git binary at the moment. Can't do patch, sorry.
Well spotted, thanks. I’ve just pushed a fix for that too.
Indeed. I can see that it is now completely fixed. Thanks a lot.