Fix TypeError caused by err_msg formatting
The retry variable can be None which causes this exception to be formatted incorrectly. Switching from %(retry)d to %(retry)s should handle the case where retry is None more gracefully. Change-Id: I592ea3e44506afb4a676d8dbe1e659a0e649424e Closes-bug: #1440755
This commit is contained in:
parent
07c3e8b049
commit
48441a64a6
@ -860,7 +860,7 @@ class Connection(object):
|
||||
# NOTE(sileht): number of retry exceeded and the connection
|
||||
# is still broken
|
||||
msg = _('Unable to connect to AMQP server on '
|
||||
'%(hostname)s:%(port)d after %(retry)d '
|
||||
'%(hostname)s:%(port)d after %(retry)s '
|
||||
'tries: %(err_str)s') % {
|
||||
'hostname': self.connection.hostname,
|
||||
'port': self.connection.port,
|
||||
|
Loading…
x
Reference in New Issue
Block a user