diff --git a/platformio/commands/debug/server.py b/platformio/commands/debug/server.py index 1d2b2a11..a129a6aa 100644 --- a/platformio/commands/debug/server.py +++ b/platformio/commands/debug/server.py @@ -131,7 +131,10 @@ class DebugServer(BaseProcess): while ( not self._process_ended and elapsed < timeout - and not (self._last_activity < (time.time() - ready_delay)) + and ( + not self._last_activity + or not (self._last_activity < (time.time() - ready_delay)) + ) ): yield self.async_sleep(delay) elapsed += delay