src/eric7/Utilities/BackgroundClient.py

branch
eric7
changeset 9485
0f3620304d7a
parent 9473
3f23dbf37dbe
child 9653
e67609152c5e
--- a/src/eric7/Utilities/BackgroundClient.py	Tue Nov 08 11:14:44 2022 +0100
+++ b/src/eric7/Utilities/BackgroundClient.py	Tue Nov 08 11:34:19 2022 +0100
@@ -10,6 +10,7 @@
 """
 
 import contextlib
+import importlib
 import io
 import json
 import multiprocessing
@@ -62,7 +63,7 @@
         """
         sys.path.insert(1, path)
         try:
-            importedModule = __import__(module, globals(), locals(), [], 0)
+            importedModule = importlib.import_module(module)
             self.services[fn] = importedModule.initService()
             with contextlib.suppress(AttributeError):
                 self.batchServices["batch_" + fn] = importedModule.initBatchService()

eric ide

mercurial