Make more friendly user outputs when training SB3
This commit is contained in:
@@ -113,7 +113,7 @@ class RequestManager(BaseModel):
|
||||
"""
|
||||
if name in self.request_types:
|
||||
msg = f"Overwriting request type {name}."
|
||||
_LOGGER.warn(msg)
|
||||
_LOGGER.debug(msg)
|
||||
|
||||
self.request_types[name] = request_type
|
||||
|
||||
|
||||
@@ -220,7 +220,7 @@ class Network(SimComponent):
|
||||
self._node_id_map[len(self.nodes)] = node
|
||||
node.parent = self
|
||||
self._nx_graph.add_node(node.hostname)
|
||||
_LOGGER.info(f"Added node {node.uuid} to Network {self.uuid}")
|
||||
_LOGGER.debug(f"Added node {node.uuid} to Network {self.uuid}")
|
||||
self._node_request_manager.add_request(name=node.uuid, request_type=RequestType(func=node._request_manager))
|
||||
|
||||
def get_node_by_hostname(self, hostname: str) -> Optional[Node]:
|
||||
|
||||
@@ -181,13 +181,13 @@ class NIC(SimComponent):
|
||||
if self.enabled:
|
||||
return
|
||||
if not self._connected_node:
|
||||
_LOGGER.error(f"NIC {self} cannot be enabled as it is not connected to a Node")
|
||||
_LOGGER.debug(f"NIC {self} cannot be enabled as it is not connected to a Node")
|
||||
return
|
||||
if self._connected_node.operating_state != NodeOperatingState.ON:
|
||||
self._connected_node.sys_log.error(f"NIC {self} cannot be enabled as the endpoint is not turned on")
|
||||
return
|
||||
if not self._connected_link:
|
||||
_LOGGER.error(f"NIC {self} cannot be enabled as it is not connected to a Link")
|
||||
_LOGGER.debug(f"NIC {self} cannot be enabled as it is not connected to a Link")
|
||||
return
|
||||
|
||||
self.enabled = True
|
||||
|
||||
Reference in New Issue
Block a user