Re: [Openstack-i18n] [openstack-dev] [nova][i18n] Is there any point in using _() inpython-novaclient?
On 9/6/2015 12:18 AM, Steve Martinelli wrote:
Isn't this just a matter of setting up novaclient for translation? IIRC using _() is harmless if there's no translation bits set up for the project.
Thanks,
Steve Martinelli OpenStack Keystone Core
Inactive hide details for Matt Riedemann ---2015/09/04 01:50:54 PM---I noticed this today: https://review.openstack.org/#/c/219Matt Riedemann ---2015/09/04 01:50:54 PM---I noticed this today: https://review.openstack.org/#/c/219768/
From: Matt Riedemann <mriedem@linux.vnet.ibm.com> To: "OpenStack Development Mailing List (not for usage questions)" <openstack-dev@lists.openstack.org>, openstack-i18n@lists.openstack.org Date: 2015/09/04 01:50 PM Subject: [openstack-dev] [nova][i18n] Is there any point in using _() in python-novaclient?
------------------------------------------------------------------------
I noticed this today:
https://review.openstack.org/#/c/219768/
And it got me thinking about something I've wondered before - why do we even use _() in python-novaclient? It doesn't have any .po files for babel message translation, it has no babel config, there is nothing in setup.cfg about extracting messages and compiling them into .mo's, there is nothing on Transifex for python-novaclient, etc.
Is there a way to change your locale and get translated output in nova CLIs? I didn't find anything in docs from a quick google search.
Comparing to python-openstackclient, that does have a babel config and some locale po files in tree, at least for de and zh_TW.
So if this doesn't work in python-novaclient, do we need any of the i18n code in there? It doesn't really hurt, but it seems pointless to push changes for it or try to keep user-facing messages in mind in the code.
--
Thanks,
Matt Riedemann
__________________________________________________________________________ OpenStack Development Mailing List (not for usage questions) Unsubscribe: OpenStack-dev-request@lists.openstack.org?subject:unsubscribe http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
__________________________________________________________________________ OpenStack Development Mailing List (not for usage questions) Unsubscribe: OpenStack-dev-request@lists.openstack.org?subject:unsubscribe http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
Yeah, doffm is working on enabling i18n for python-novaclient via bug: https://bugs.launchpad.net/python-novaclient/+bug/1492444 -- Thanks, Matt Riedemann
With the limited resources that the translation team has, we should not translate the clients but concentrate on the openstackclient, as discussed here: http://lists.openstack.org/pipermail/openstack-i18n/2015-September/001402.ht... Andreas -- Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
On 18 September 2015 at 15:46, Andreas Jaeger <aj@suse.com> wrote:
With the limited resources that the translation team has, we should not translate the clients but concentrate on the openstackclient, as discussed here:
http://lists.openstack.org/pipermail/openstack-i18n/2015-September/001402.ht...
Given the current plans, that makes sense, I think. Matt, thank you for raising this. johnthetubaguy
Certainly for cinder, and I suspect many other project, the openstack client is a wrapper for python-cinderclient libraries, so if you want translated exceptions then you need to translate python-cinderclient too, unless I'm missing something? On 18 September 2015 at 17:46, Andreas Jaeger <aj@suse.com> wrote:
With the limited resources that the translation team has, we should not translate the clients but concentrate on the openstackclient, as discussed here:
http://lists.openstack.org/pipermail/openstack-i18n/2015-September/001402.ht...
Andreas -- Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
_______________________________________________ Openstack-i18n mailing list Openstack-i18n@lists.openstack.org http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-i18n
-- -- Duncan Thomas
On 09/20/2015 02:16 PM, Duncan Thomas wrote:
Certainly for cinder, and I suspect many other project, the openstack client is a wrapper for python-cinderclient libraries, so if you want translated exceptions then you need to translate python-cinderclient too, unless I'm missing something?
Ah - let's investigate some more here. Looking at python-cinderclient, I see translations only for the help strings of the client like in cinderclient/shell.py. Are there strings in the library of cinder that will be displayed to the user as well? Andreas
On 18 September 2015 at 17:46, Andreas Jaeger <aj@suse.com <mailto:aj@suse.com>> wrote:
With the limited resources that the translation team has, we should not translate the clients but concentrate on the openstackclient, as discussed here:
http://lists.openstack.org/pipermail/openstack-i18n/2015-September/001402.ht...
Andreas -- Andreas Jaeger aj@{suse.com <http://suse.com>,opensuse.org <http://opensuse.org>} Twitter/Identica: jaegerandi SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
_______________________________________________ Openstack-i18n mailing list Openstack-i18n@lists.openstack.org <mailto:Openstack-i18n@lists.openstack.org> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-i18n
-- -- Duncan Thomas
-- Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
On 09/20/2015 03:06 PM, Andreas Jaeger wrote:
On 09/20/2015 02:16 PM, Duncan Thomas wrote:
Certainly for cinder, and I suspect many other project, the openstack client is a wrapper for python-cinderclient libraries, so if you want translated exceptions then you need to translate python-cinderclient too, unless I'm missing something?
Ah - let's investigate some more here.
Looking at python-cinderclient, I see translations only for the help strings of the client like in cinderclient/shell.py. Are there strings in the library of cinder that will be displayed to the user as well?
We discussed on the i18n team list and will enable those repos if the teams send patches. The i18n team will prioritize which resources gets translated, Andreas -- Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
That sounds like the right solution Andreas. thanks! -- Dims On Fri, Sep 25, 2015 at 1:42 AM, Andreas Jaeger <aj@suse.com> wrote:
On 09/20/2015 03:06 PM, Andreas Jaeger wrote:
On 09/20/2015 02:16 PM, Duncan Thomas wrote:
Certainly for cinder, and I suspect many other project, the openstack client is a wrapper for python-cinderclient libraries, so if you want translated exceptions then you need to translate python-cinderclient too, unless I'm missing something?
Ah - let's investigate some more here.
Looking at python-cinderclient, I see translations only for the help strings of the client like in cinderclient/shell.py. Are there strings in the library of cinder that will be displayed to the user as well?
We discussed on the i18n team list and will enable those repos if the teams send patches. The i18n team will prioritize which resources gets translated,
Andreas -- Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
_______________________________________________ Openstack-i18n mailing list Openstack-i18n@lists.openstack.org http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-i18n
-- Davanum Srinivas :: https://twitter.com/dims
participants (5)
-
Andreas Jaeger
-
Davanum Srinivas
-
Duncan Thomas
-
John Garbutt
-
Matt Riedemann