From b88ea86ef4dd5732ca1c3438686b690890d7f972 Mon Sep 17 00:00:00 2001 From: Konstantin Leontev Date: Mon, 22 May 2023 12:51:32 +0100 Subject: [PATCH] [bos #35167][CEA] Salome process gets detached. Reverted commented import, added early return and debug message for not found session. --- bin/runSalome.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/bin/runSalome.py b/bin/runSalome.py index 1a0e1134b..4e22e7ad6 100755 --- a/bin/runSalome.py +++ b/bin/runSalome.py @@ -230,7 +230,7 @@ def foreGround(args, ior_fakens_filename): return import CORBA #import Engines - #import SALOME + import SALOME from time import sleep orb = CORBA.ORB_init([''], CORBA.ORB_ID) ior_fakens = None @@ -254,6 +254,11 @@ def foreGround(args, ior_fakens_filename): logger.debug("Unfortunately Session not found into {} : Sleep and retry. {}/{}".format(ior_fakens_filename,nb,nbtot)) if nb == nbtot: break + + if session is None: + logger.debug("Couldn't find /Kernel/Session in the child process. Return.") + return + nb = 0 # -- # Wait until gui is arrived @@ -277,6 +282,7 @@ def foreGround(args, ior_fakens_filename): pass # -- if not gui_detected: + logger.debug("Couldn't find active GUI in the current session. Return.") return # -- from salome_utils import getPortNumber -- 2.39.2