[Bug 35091] New: Improve translation of usage statistics country list
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Bug ID: 35091 Summary: Improve translation of usage statistics country list Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: ASSIGNED Severity: enhancement Priority: P5 - low Component: I18N/L10N Assignee: oleonard@myacpl.org Reporter: oleonard@myacpl.org QA Contact: testopia@bugs.koha-community.org CC: frederic@tamil.fr The usage statistics page uses an include file, country-list.inc, which contains a large list of country names. When this include file is processed for translation the entire list shows up as one string: #: koha-tmpl/intranet-tmpl/prog/en/includes/country-list.inc:1 #, c-format msgid "[%% SET countries = [ \"Afghanistan\", \"Albania\", \"Algeria\", \"Andorra\"... This file should be reworked so that each country is a separate string in translations. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 --- Comment #1 from Owen Leonard <oleonard@myacpl.org> --- Created attachment 157336 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=157336&action=edit Bug 35091: Improve translation of usage statistics country list This patch reworks country-list.inc so that each country name can be wrapped separately in the t() translation function and be processed individually during the translation process. To test, apply the patch and update a translation, e.g. fr-FR: - perl misc/translator/translate update fr-FR - Edit the updated po file for the language you chose, e.g. misc/translator/po/fr-FR-messages.po, and locate strings from country-strings.inc. Each country names should show up as a separate string for translation. - Update the file to fill in translated strings for one or more countries. For example: koha-tmpl/intranet-tmpl/prog/en/includes/country-list.inc:2 msgid "Afghanistan" msgstr "" - Install the updated po file: - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Go to Administration -> Share usage statistics and check the "Your country" dropdown. The list should look correct. - Switch to your updated translation and confirm that the country names you translated show up as expected. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |35097 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35097 [Bug 35097] Use country-list.inc to display choices for UsageStatsCountry preference -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #157336|0 |1 is obsolete| | --- Comment #2 from Lucas Gass <lucas@bywatersolutions.com> --- Created attachment 157362 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=157362&action=edit Bug 35091: Improve translation of usage statistics country list This patch reworks country-list.inc so that each country name can be wrapped separately in the t() translation function and be processed individually during the translation process. To test, apply the patch and update a translation, e.g. fr-FR: - perl misc/translator/translate update fr-FR - Edit the updated po file for the language you chose, e.g. misc/translator/po/fr-FR-messages.po, and locate strings from country-strings.inc. Each country names should show up as a separate string for translation. - Update the file to fill in translated strings for one or more countries. For example: koha-tmpl/intranet-tmpl/prog/en/includes/country-list.inc:2 msgid "Afghanistan" msgstr "" - Install the updated po file: - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Go to Administration -> Share usage statistics and check the "Your country" dropdown. The list should look correct. - Switch to your updated translation and confirm that the country names you translated show up as expected. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |david@davidnind.com --- Comment #3 from David Nind <david@davidnind.com> --- Hi Lucas. It looks to me like you've signed this off, but the status hasn't been changed 8-) David -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #157362|0 |1 is obsolete| | --- Comment #4 from David Nind <david@davidnind.com> --- Created attachment 157598 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=157598&action=edit Bug 35091: Improve translation of usage statistics country list This patch reworks country-list.inc so that each country name can be wrapped separately in the t() translation function and be processed individually during the translation process. To test, apply the patch and update a translation, e.g. fr-FR: - perl misc/translator/translate update fr-FR - Edit the updated po file for the language you chose, e.g. misc/translator/po/fr-FR-messages.po, and locate strings from country-strings.inc. Each country names should show up as a separate string for translation. - Update the file to fill in translated strings for one or more countries. For example: koha-tmpl/intranet-tmpl/prog/en/includes/country-list.inc:2 msgid "Afghanistan" msgstr "" - Install the updated po file: - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Go to Administration -> Share usage statistics and check the "Your country" dropdown. The list should look correct. - Switch to your updated translation and confirm that the country names you translated show up as expected. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 --- Comment #5 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- This is a good improvement, but got me thinking, because I quite hated translating all these :) Currently we maintain at least 2 country lists. The other is the authorised value COUNTRY. And both string sets end up in different translation files. I am hoping the suggestion feature on Weblate/Pootle will help here now :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=35213 --- Comment #6 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hm, OK - not a problem of this patch, but what we are doing here is a bit strange, we should store country codes, not the names that can change when translated: Bug 35213 - Standardize country information sent to Hea -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #157598|0 |1 is obsolete| | --- Comment #7 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 158175 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158175&action=edit Bug 35091: Improve translation of usage statistics country list This patch reworks country-list.inc so that each country name can be wrapped separately in the t() translation function and be processed individually during the translation process. To test, apply the patch and update a translation, e.g. fr-FR: - perl misc/translator/translate update fr-FR - Edit the updated po file for the language you chose, e.g. misc/translator/po/fr-FR-messages.po, and locate strings from country-strings.inc. Each country names should show up as a separate string for translation. - Update the file to fill in translated strings for one or more countries. For example: koha-tmpl/intranet-tmpl/prog/en/includes/country-list.inc:2 msgid "Afghanistan" msgstr "" - Install the updated po file: - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Go to Administration -> Share usage statistics and check the "Your country" dropdown. The list should look correct. - Switch to your updated translation and confirm that the country names you translated show up as expected. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |23.11.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 --- Comment #8 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Pushed to master for 23.11. Nice work everyone, thanks! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35091 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m Status|Pushed to master |RESOLVED Resolution|--- |FIXED --- Comment #9 from Fridolin Somers <fridolin.somers@biblibre.com> --- Enhancement not pushed to 23.05.x -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org