From cb72dfd9569bcf515738c5570c6d556e22da5b60 Mon Sep 17 00:00:00 2001 From: Maxime Rey <87315832+MaxJPRey@users.noreply.github.com> Date: Fri, 1 Sep 2023 19:27:00 +0200 Subject: [PATCH] Follow pythonic naming convention for variables. --- src/ansys/workbench/core/launch_workbench.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ansys/workbench/core/launch_workbench.py b/src/ansys/workbench/core/launch_workbench.py index 20a7beb..dd7473b 100644 --- a/src/ansys/workbench/core/launch_workbench.py +++ b/src/ansys/workbench/core/launch_workbench.py @@ -49,20 +49,20 @@ def _launch_server(self): logging.warning("ANSYS installation not found. Assume the default location: " + install_path) else: logging.info("ANSYS installation found at: " + install_path) - exePath = os.path.join(install_path, "Framework", "bin", "Win64", "RunWB2.exe") + executable = os.path.join(install_path, "Framework", "bin", "Win64", "RunWB2.exe") prefix = uuid.uuid4().hex workdir_arg = '' if self._server_workdir is not None: workdir_arg = ",WorkingDirectory=\'" + self._server_workdir + "\'" - cmdLine = exePath + " -I -E \"StartServer(EnvironmentPrefix=\'" + prefix + "\'" + workdir_arg + ")\"" + command = executable + " -I -E \"StartServer(EnvironmentPrefix=\'" + prefix + "\'" + workdir_arg + ")\"" process_startup_info = self._wmi_connection.Win32_ProcessStartup.new(ShowWindow=1) process_id, result = self._wmi_connection.Win32_Process.Create( - CommandLine = cmdLine, + CommandLine = command, ProcessStartupInformation = process_startup_info) if result == 0: - logging.info("Workbench launched on the host with process id " + str(process_id)) + logging.info("Workbench launched on the host with process id: " + str(process_id)) self._process_id = process_id else: logging.error("Workbench failed to launch on the host")