From 224a59b054bc4a7e2ef6843c4a9b390e53733ec2 Mon Sep 17 00:00:00 2001 From: LmeSzinc <37934724+LmeSzinc@users.noreply.github.com> Date: Fri, 30 Aug 2024 18:50:53 +0800 Subject: [PATCH] Fix: [ALAS] Catch OSError when iter running emulators (cherry picked from commit dc530e75386d4575a36bc52a76bf41c2aecd8898) --- module/device/platform/emulator_windows.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/module/device/platform/emulator_windows.py b/module/device/platform/emulator_windows.py index 4095ba9e7..e3dd74020 100644 --- a/module/device/platform/emulator_windows.py +++ b/module/device/platform/emulator_windows.py @@ -506,9 +506,10 @@ class EmulatorManager(EmulatorManagerBase): try: exe = proc.cmdline() exe = exe[0].replace(r'\\', '/').replace('\\', '/') - except (psutil.AccessDenied, psutil.NoSuchProcess, IndexError): + except (psutil.AccessDenied, psutil.NoSuchProcess, IndexError, OSError): # psutil.AccessDenied # NoSuchProcess: process no longer exists (pid=xxx) + # OSError: [WinError 87] 参数错误。: '(originated from ReadProcessMemory)' continue if Emulator.is_emulator(exe):