From fb5e3908917199810c54ffbdc433e9cd327133b1 Mon Sep 17 00:00:00 2001 From: liyi Date: Tue, 21 Mar 2017 13:01:13 +0800 Subject: Remove log translations Log messages are no longer being translated. This removes all use of the _LE, _LI, and _LW translation markers to simplify logging and to avoid confusion with new contributions. See: http://lists.openstack.org/pipermail/openstack-i18n/2016-November/002574.html http://lists.openstack.org/pipermail/openstack-dev/2017-March/113365.html Change-Id: I601eee9f1fca65d5fb53e6b75482b74283908a29 --- heatclient/common/hook_utils.py | 5 ++--- heatclient/common/http.py | 3 +-- heatclient/common/utils.py | 3 +-- 3 files changed, 4 insertions(+), 7 deletions(-) (limited to 'heatclient/common') diff --git a/heatclient/common/hook_utils.py b/heatclient/common/hook_utils.py index 66b980a..e970690 100644 --- a/heatclient/common/hook_utils.py +++ b/heatclient/common/hook_utils.py @@ -15,7 +15,6 @@ import logging from oslo_utils import fnmatch from heatclient._i18n import _ -from heatclient._i18n import _LE from heatclient import exc logger = logging.getLogger(__name__) @@ -29,8 +28,8 @@ def clear_hook(hc, stack_id, resource_name, hook_type): data={'unset_hook': hook_type}) except exc.HTTPNotFound: logger.error( - _LE("Stack %(stack)s or resource %(resource)s " - "not found for hook %(hook_type)"), + "Stack %(stack)s or resource %(resource)s " + "not found for hook %(hook_type)", {'resource': resource_name, 'stack': stack_id, 'hook_type': hook_type}) diff --git a/heatclient/common/http.py b/heatclient/common/http.py index 68d2908..f5c5021 100644 --- a/heatclient/common/http.py +++ b/heatclient/common/http.py @@ -28,7 +28,6 @@ import six from six.moves.urllib import parse from heatclient._i18n import _ -from heatclient._i18n import _LW from heatclient.common import utils from heatclient import exc @@ -67,7 +66,7 @@ def get_system_ca_file(): if os.path.exists(ca): LOG.debug("Using ca file %s", ca) return ca - LOG.warning(_LW("System ca file could not be found.")) + LOG.warning("System ca file could not be found.") class HTTPClient(object): diff --git a/heatclient/common/utils.py b/heatclient/common/utils.py index 047b709..013e692 100644 --- a/heatclient/common/utils.py +++ b/heatclient/common/utils.py @@ -29,7 +29,6 @@ from six.moves.urllib import request import yaml from heatclient._i18n import _ -from heatclient._i18n import _LE from heatclient import exc LOG = logging.getLogger(__name__) @@ -444,7 +443,7 @@ def get_response_body(resp): try: body = resp.json() except ValueError: - LOG.error(_LE('Could not decode response body as JSON')) + LOG.error('Could not decode response body as JSON') else: body = None return body -- cgit v1.2.1