From 0d0c9081168344abc8b0ee27566a0ec41c95e056 Mon Sep 17 00:00:00 2001
From: gifrerenom <lluis.gifre@cttc.es>
Date: Tue, 12 Sep 2023 16:27:04 +0000
Subject: [PATCH] Common - Context Queries:

- Added field name in create_topology method
---
 src/common/tools/context_queries/Topology.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/common/tools/context_queries/Topology.py b/src/common/tools/context_queries/Topology.py
index 15217b8d1..7759916b5 100644
--- a/src/common/tools/context_queries/Topology.py
+++ b/src/common/tools/context_queries/Topology.py
@@ -23,13 +23,13 @@ from context.client.ContextClient import ContextClient
 LOGGER = logging.getLogger(__name__)
 
 def create_topology(
-    context_client : ContextClient, context_uuid : str, topology_uuid : str
+    context_client : ContextClient, context_uuid : str, topology_uuid : str, name : Optional[str] = None
 ) -> None:
     context_id = ContextId(**json_context_id(context_uuid))
     existing_topology_ids = context_client.ListTopologyIds(context_id)
     existing_topology_uuids = {topology_id.topology_uuid.uuid for topology_id in existing_topology_ids.topology_ids}
     if topology_uuid in existing_topology_uuids: return
-    context_client.SetTopology(Topology(**json_topology(topology_uuid, context_id=context_id)))
+    context_client.SetTopology(Topology(**json_topology(topology_uuid, context_id=context_id, name=name)))
 
 def create_missing_topologies(
     context_client : ContextClient, context_id : ContextId, topology_uuids : List[str]
-- 
GitLab