From c9d2c85721761edfbeb524adaa2c6ce1a1affcae Mon Sep 17 00:00:00 2001 From: Sebastian Garcia Date: Wed, 3 Sep 2025 23:33:19 +0200 Subject: [PATCH] Fix the the netsecenv an issue not reading all the data from each host while reading the configuration --- AIDojoCoordinator/worlds/NSEGameCoordinator.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/AIDojoCoordinator/worlds/NSEGameCoordinator.py b/AIDojoCoordinator/worlds/NSEGameCoordinator.py index 0917b99a..35a27ada 100644 --- a/AIDojoCoordinator/worlds/NSEGameCoordinator.py +++ b/AIDojoCoordinator/worlds/NSEGameCoordinator.py @@ -229,15 +229,22 @@ def process_node_config(node_obj:NodeConfig) -> None: self.logger.info(f"\t\t\tProcessing data in node '{node_obj.id}':'{service.name}' service") try: for data in service.private_data: + self.logger.info(f"\t\t\t\tData: {data}") if node_obj.id not in self._data: self._data[node_obj.id] = set() datapoint = Data(data.owner, data.description) self._data[node_obj.id].add(datapoint) # add content - self._data_content[node_obj.id, datapoint.id] = f"Content of {datapoint.id}" + try: + self._data_content[node_obj.id, datapoint.id] = f"Content of {datapoint.id}" + except AttributeError: + # If self._data_content does not exist, create it here. + self._data_content = {} + self._data_content[node_obj.id, datapoint.id] = f"Content of {datapoint.id}" except AttributeError: + # Service does not contain any data pass - #service does not contain any data + def process_router_config(router_obj:RouterConfig)->None: self.logger.info(f"\tProcessing config of router '{router_obj.id}'") # Process a router