Merge "Use new log style when LOG.error"
This commit is contained in:
commit
f5057aa30b
@ -1091,7 +1091,7 @@ def servers_update_addresses(request, servers, all_tenants=False):
|
||||
ports_floating_ips,
|
||||
network_names)
|
||||
except Exception as e:
|
||||
LOG.error(e)
|
||||
LOG.error(six.text_type(e))
|
||||
else:
|
||||
server.addresses = addresses
|
||||
|
||||
|
@ -21,6 +21,7 @@ import logging
|
||||
import operator
|
||||
|
||||
from oslo_utils import units
|
||||
import six
|
||||
|
||||
from django.template.defaultfilters import filesizeformat # noqa
|
||||
from django.utils.text import normalize_newlines # noqa
|
||||
@ -688,7 +689,8 @@ class CustomizeAction(workflows.Action):
|
||||
except Exception as e:
|
||||
msg = _('There was a problem parsing the'
|
||||
' %(prefix)s: %(error)s')
|
||||
msg = msg % {'prefix': prefix, 'error': e}
|
||||
msg = msg % {'prefix': prefix,
|
||||
'error': six.text_type(e)}
|
||||
raise forms.ValidationError(msg)
|
||||
return script
|
||||
else:
|
||||
|
@ -191,7 +191,7 @@ class TemplateForm(forms.SelfHandlingForm):
|
||||
except Exception as e:
|
||||
msg = _('There was a problem parsing the'
|
||||
' %(prefix)s: %(error)s')
|
||||
msg = msg % {'prefix': prefix, 'error': e}
|
||||
msg = msg % {'prefix': prefix, 'error': six.text_type(e)}
|
||||
raise forms.ValidationError(msg)
|
||||
cleaned[data_str] = tpl
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user