]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
[EDF29852] : Ready to log replay sessions agy/29852
authorAnthony Geay <anthony.geay@edf.fr>
Thu, 28 Mar 2024 13:28:49 +0000 (14:28 +0100)
committerAnthony Geay <anthony.geay@edf.fr>
Thu, 28 Mar 2024 13:28:49 +0000 (14:28 +0100)
src/KERNEL_PY/__init__.py

index 61533250055563a1a95e9fa39b7b7f632c71f182..6d7d73211f837fd94006e9254f551918d94eb4b7 100644 (file)
@@ -430,11 +430,13 @@ def salome_shutdown_containers_with_session():
 
 def retrieve_containers_in_ns():
     return [elt for elt in naming_service.repr() if "/Containers/" == elt[:12]]
+
+def get_all_containers():
+    containersEntries = retrieve_containers_in_ns()
+    return [naming_service.Resolve(containerEntry) for containerEntry in containersEntries]
     
 def salome_shutdown_containers_without_session():
-    containersEntries = retrieve_containers_in_ns()
-    for containerEntry in containersEntries:
-        cont = naming_service.Resolve(containerEntry)
+    for cont in get_all_containers():
         try:
             cont.Shutdown()
         except: