Python 3 deprecated the logger.warn method in favor of warning
Python 3 deprecated the logger.warn method, see: https://docs.python.org/3/library/logging.html#logging.warning, so we prefer to use warning to avoid DeprecationWarning. Closes-Bug: #1529913 Change-Id: I5d6d85b1ee4a63ebfb3348c093e37ab48b713e40
This commit is contained in:
@@ -54,7 +54,7 @@ def acquire_port(host):
|
||||
ALLOCATED_PORTS.add((host, port))
|
||||
return port
|
||||
except exception.SocketPortInUseException as e:
|
||||
LOG.warn(e.format_message())
|
||||
LOG.warning(e.format_message())
|
||||
|
||||
raise exception.SocketPortRangeExhaustedException(host=host)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user