From 57ae7199f10ba74841271bdb5dc1b495fa5ca97a Mon Sep 17 00:00:00 2001 From: Martin Milata Date: Thu, 27 Feb 2025 10:31:14 +0100 Subject: [PATCH] fixup! fix(python): runaway emulator process --- python/src/trezorlib/_internal/emulator.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/python/src/trezorlib/_internal/emulator.py b/python/src/trezorlib/_internal/emulator.py index acdf131f8a..8ec49a8690 100644 --- a/python/src/trezorlib/_internal/emulator.py +++ b/python/src/trezorlib/_internal/emulator.py @@ -138,8 +138,6 @@ class Emulator: LOG.info(f"Emulator ready after {time.monotonic() - start:.3f} seconds") def wait(self, timeout: Optional[float] = None) -> int: - global _RUNNING_PIDS - assert self.process is not None, "Emulator not started" ret = self.process.wait(timeout=timeout) _RUNNING_PIDS.remove(self.process) @@ -167,8 +165,6 @@ class Emulator: ) def start(self) -> None: - global _RUNNING_PIDS - if self.process: if self.process.poll() is not None: # process has died, stop and start again @@ -198,8 +194,6 @@ class Emulator: self._client.open() def stop(self) -> None: - global _RUNNING_PIDS - if self._client: self._client.close() self._client = None