eric6/Utilities/BackgroundClient.py

changeset 8243
cc717c2ae956
parent 8240
93b8a353c4bf
child 8264
f95dde35d0ab
--- a/eric6/Utilities/BackgroundClient.py	Thu Apr 15 16:52:05 2021 +0200
+++ b/eric6/Utilities/BackgroundClient.py	Thu Apr 15 18:11:24 2021 +0200
@@ -61,12 +61,10 @@
         try:
             importedModule = __import__(module, globals(), locals(), [], 0)
             self.services[fn] = importedModule.initService()
-            try:
+            with contextlib.suppress(AttributeError):
                 self.batchServices["batch_" + fn] = (
                     importedModule.initBatchService()
                 )
-            except AttributeError:
-                pass
             return 'ok'
         except ImportError:
             return 'Import Error'

eric ide

mercurial