From 041e7764a8672d5cc77465abebf24c74416cd841 Mon Sep 17 00:00:00 2001 From: Jimmy Christensen Date: Sat, 9 Nov 2024 18:34:20 +0100 Subject: [PATCH 1/2] Switch from using subprocess.check_call to subprocess.Popen which doesn't lock the UI until the process returns an exist code --- cuegui/cuegui/Utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cuegui/cuegui/Utils.py b/cuegui/cuegui/Utils.py index b59789d4b..3ae70da8e 100644 --- a/cuegui/cuegui/Utils.py +++ b/cuegui/cuegui/Utils.py @@ -666,7 +666,7 @@ def launchViewerUsingPaths(paths, actionText, test_mode=False): if not test_mode: print(msg) try: - subprocess.check_call(cmd.split()) + subprocess.Popen(cmd.split()) except subprocess.CalledProcessError as e: showErrorMessageBox(str(e), title='Error running Viewer command') except Exception as e: From a808196ef22e468bbf90a0509121b0969b24bafe Mon Sep 17 00:00:00 2001 From: Jimmy Christensen Date: Sat, 9 Nov 2024 19:15:54 +0100 Subject: [PATCH 2/2] Fix pylint for Popen call --- cuegui/cuegui/Utils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/cuegui/cuegui/Utils.py b/cuegui/cuegui/Utils.py index 3ae70da8e..2dfeb3673 100644 --- a/cuegui/cuegui/Utils.py +++ b/cuegui/cuegui/Utils.py @@ -666,6 +666,7 @@ def launchViewerUsingPaths(paths, actionText, test_mode=False): if not test_mode: print(msg) try: + # pylint: disable=consider-using-with subprocess.Popen(cmd.split()) except subprocess.CalledProcessError as e: showErrorMessageBox(str(e), title='Error running Viewer command')