src/eric7/Debugger/DebuggerInterfacePython.py

branch
eric7
changeset 10956
1c22b555df34
parent 10930
5a883e68aa35
child 10966
2ae7fc2a852b
--- a/src/eric7/Debugger/DebuggerInterfacePython.py	Sun Oct 06 10:10:08 2024 +0200
+++ b/src/eric7/Debugger/DebuggerInterfacePython.py	Sun Oct 06 12:18:51 2024 +0200
@@ -863,9 +863,10 @@
                         self.__mainDebugger, jsonStr
                     )
             else:
-                conn = self.__connections[self.__mainDebugger]
-                for jsonStr in self.__commandQueue:
-                    self.__writeJsonCommandToSocket(jsonStr, conn)
+                with contextlib.suppress(KeyError):
+                    conn = self.__connections[self.__mainDebugger]
+                    for jsonStr in self.__commandQueue:
+                        self.__writeJsonCommandToSocket(jsonStr, conn)
 
         self.__commandQueue.clear()
 

eric ide

mercurial