From 0f59c13278a42c41bb7d4582f8412b708e81863e Mon Sep 17 00:00:00 2001 From: Ken Chen Date: Sat, 28 Feb 2015 11:39:48 +0800 Subject: [PATCH] Fix some translator mistakes Change some "_" into "_LE" or "_LW" accordingly. Closes-Bug: #1426617 Change-Id: I4c3413df7cf35b2bdc9f441a93198bc06e70c21f --- sahara/utils/openstack/cinder.py | 16 ++++++++-------- sahara/utils/proxy.py | 2 +- sahara/utils/ssh_remote.py | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/sahara/utils/openstack/cinder.py b/sahara/utils/openstack/cinder.py index 339d3f03..fc726d55 100644 --- a/sahara/utils/openstack/cinder.py +++ b/sahara/utils/openstack/cinder.py @@ -21,7 +21,7 @@ from oslo_config import cfg from oslo_log import log as logging from sahara import context -from sahara.i18n import _ +from sahara.i18n import _LW from sahara.utils.openstack import base @@ -50,14 +50,14 @@ CONF.register_opts(opts, group=cinder_group) def validate_config(): if CONF.cinder.api_version == 1: - LOG.warn(_('The Cinder v1 API is deprecated and will be removed after ' - 'the Juno release. You should set cinder.api_version=2 in ' - 'your sahara.conf file.')) + LOG.warn(_LW('The Cinder v1 API is deprecated and will be removed ' + 'after the Juno release. You should set ' + 'cinder.api_version=2 in your sahara.conf file.')) elif CONF.cinder.api_version != 2: - LOG.warn(_('Unsupported Cinder API version: %(bad)s. Please set a ' - 'correct value for cinder.api_version in your sahara.conf ' - 'file (currently supported versions are: %(supported)s). ' - 'Falling back to Cinder API version 2.'), + LOG.warn(_LW('Unsupported Cinder API version: %(bad)s. Please set a ' + 'correct value for cinder.api_version in your sahara.conf' + ' file (currently supported versions are: %(supported)s).' + ' Falling back to Cinder API version 2.'), {'bad': CONF.cinder.api_version, 'supported': [1, 2]}) CONF.set_override('api_version', 2, group='cinder') diff --git a/sahara/utils/proxy.py b/sahara/utils/proxy.py index 544ef973..787a267e 100644 --- a/sahara/utils/proxy.py +++ b/sahara/utils/proxy.py @@ -263,7 +263,7 @@ def proxy_user_create(username): domain = domain_for_proxy() password = six.text_type(uuid.uuid4()) admin.users.create(name=username, password=password, domain=domain.id) - LOG.debug(_('created proxy user {0}').format(username)) + LOG.debug('created proxy user {0}'.format(username)) return password diff --git a/sahara/utils/ssh_remote.py b/sahara/utils/ssh_remote.py index 7a223628..19b53ef6 100644 --- a/sahara/utils/ssh_remote.py +++ b/sahara/utils/ssh_remote.py @@ -571,7 +571,7 @@ class InstanceInteropHelper(remote.Remote): try: command = command.format(**keywords) except KeyError as e: - LOG.error(_('Invalid keyword in proxy_command: %s'), str(e)) + LOG.error(_LE('Invalid keyword in proxy_command: %s'), str(e)) # Do not give more details to the end-user raise ex.SystemError('Misconfiguration') if rootwrap_command: