eric6/DebugClients/Python/BreakpointWatch.py

changeset 8243
cc717c2ae956
parent 8240
93b8a353c4bf
child 8273
698ae46f40a4
--- a/eric6/DebugClients/Python/BreakpointWatch.py	Thu Apr 15 16:52:05 2021 +0200
+++ b/eric6/DebugClients/Python/BreakpointWatch.py	Thu Apr 15 18:11:24 2021 +0200
@@ -61,13 +61,11 @@
         """
         Public method to clear this breakpoint.
         """
-        try:
+        with contextlib.suppress(KeyError):
             del Breakpoint.breaks[(self.file, self.line)]
             Breakpoint.breakInFile[self.file].remove(self.line)
             if not Breakpoint.breakInFile[self.file]:
                 del Breakpoint.breakInFile[self.file]
-        except KeyError:
-            pass
 
     def enable(self):
         """

eric ide

mercurial