Replacement _ on _LW in all LOG.warning part 1
oslo.i18n uses different marker functions to separate the translatable messages into different catalogs, which the translation teams can prioritize translating. For details, please refer to: http://docs.openstack.org/developer/oslo.i18n/guidelines.html#guidelines-for-use-in-openstack There were not marker fuctions some places in directory network. This commit makes changes: * Add missing marker functions * Use ',' instead of '%' while adding variables to log messages Added a hacking rule for the warning about checking translation for it and checking logging level `warning` instead alias `warn`. Change-Id: I2bced49dc5a0408a94d5d20d85b20c682886edbe
This commit is contained in:
@@ -60,7 +60,7 @@ def init():
|
||||
if not (CONF.remote_debug.host and CONF.remote_debug.port):
|
||||
return
|
||||
|
||||
from nova.i18n import _
|
||||
from nova.i18n import _LW
|
||||
from nova.openstack.common import log as logging
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
@@ -77,7 +77,7 @@ def init():
|
||||
stdoutToServer=False,
|
||||
stderrToServer=False)
|
||||
|
||||
LOG.warn(_('WARNING: Using the remote debug option changes how '
|
||||
'Nova uses the eventlet library to support async IO. This '
|
||||
'could result in failures that do not occur under normal '
|
||||
'operation. Use at your own risk.'))
|
||||
LOG.warning(_LW('WARNING: Using the remote debug option changes how '
|
||||
'Nova uses the eventlet library to support async IO. This '
|
||||
'could result in failures that do not occur under normal '
|
||||
'operation. Use at your own risk.'))
|
||||
|
||||
Reference in New Issue
Block a user