src/eric7/QScintilla/DocstringGenerator/BaseDocstringGenerator.py

branch
eric7
changeset 9497
8beca4047c53
parent 9486
5a8179763e38
child 9500
5771348ded12
--- a/src/eric7/QScintilla/DocstringGenerator/BaseDocstringGenerator.py	Wed Nov 09 10:37:21 2022 +0100
+++ b/src/eric7/QScintilla/DocstringGenerator/BaseDocstringGenerator.py	Wed Nov 09 10:59:01 2022 +0100
@@ -143,16 +143,14 @@
         @rtype str
         """
         generatorModuleMapping = {
-            "ericdoc": "EricdocGenerator",
-            "numpydoc": "NumpydocGenerator",
-            "goodledoc": "GoogledocGenerator",
-            "sphinxdoc": "SphinxdocGenerator",
+            "ericdoc": ".EricdocGenerator",
+            "numpydoc": ".NumpydocGenerator",
+            "goodledoc": ".GoogledocGenerator",
+            "sphinxdoc": ".SphinxdocGenerator",
         }
         if docstringType in generatorModuleMapping:
             mod = importlib.import_module(
-                "eric7.QScintilla.DocstringGenerator.{0}".format(
-                    generatorModuleMapping[docstringType]
-                )
+                generatorModuleMapping[docstringType], __package__
             )
             return mod.generateDoc(functionInfo, self.editor)
 

eric ide

mercurial