From: Cédric Aguerre Date: Fri, 13 Sep 2024 08:09:12 +0000 (+0200) Subject: [30875] Fix missing f-string in error message X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=9759231a21b26b0d6dc785d6a1b55634ed0e67e5;p=modules%2Fkernel.git [30875] Fix missing f-string in error message --- diff --git a/src/Container/SALOME_PyNode.py b/src/Container/SALOME_PyNode.py index 8cbbca922..c642d2b14 100644 --- a/src/Container/SALOME_PyNode.py +++ b/src/Container/SALOME_PyNode.py @@ -1042,7 +1042,7 @@ def ExchangeModeServerSideFactory( exchangeMode ): elif exchangeMode == "TCP": return ExchangeContextUsingTCP() else: - raise RuntimeError( "ExchangeModeServerSideFactory : {} not in [File,TCP]" ) + raise RuntimeError( f"ExchangeModeServerSideFactory : {exchangeMode} not in [File,TCP]" ) class ExchangeContextCltAbs(abc.ABC): def __init__(self): @@ -1120,7 +1120,7 @@ def ExchangeModeCltSideFactory( exchangeMode, keepFilesToReplay ): elif exchangeMode == "TCP": return ExchangeContextUsingTCPClt() else: - raise RuntimeError( "ExchangeModeCltSideFactory : {} not in [File,TCP]" ) + raise RuntimeError( f"ExchangeModeCltSideFactory : {exchangeMode} not in [File,TCP]" ) def ExecCrashProofGeneric( code, context, outargsname, containerRef, instanceOfLogOfCurrentSession, keepFilesToReplay, closeEyesOnErrorAtExit): """