eric6/DebugClients/Python/DebugVariables.py

changeset 8240
93b8a353c4bf
parent 8220
006ee31b4835
child 8243
cc717c2ae956
--- a/eric6/DebugClients/Python/DebugVariables.py	Wed Apr 14 19:38:19 2021 +0200
+++ b/eric6/DebugClients/Python/DebugVariables.py	Wed Apr 14 19:59:16 2021 +0200
@@ -7,6 +7,8 @@
 Module implementing classes and functions to dump variable contents.
 """
 
+import contextlib
+
 from DebugConfig import ConfigQtNames, ConfigKnownQtTypes, BatchSize
 
 #
@@ -653,10 +655,8 @@
         (frozenset, setResolver),
     ]
     
-    try:
+    with contextlib.suppress(Exception):
         _TypeMap.append((long, None))           # __IGNORE_WARNING__
-    except Exception:       # secok
-        pass    # not available on all Python versions
 
     try:
         import array

eric ide

mercurial