Corrected an issue causing the pip dependency tree and the pip licenses dialogs to not show anything on Windows. eric7

Sat, 03 Sep 2022 17:16:33 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sat, 03 Sep 2022 17:16:33 +0200
branch
eric7
changeset 9309
60ee3f038f52
parent 9308
110d32f96013
child 9310
8ab45a4a6d96

Corrected an issue causing the pip dependency tree and the pip licenses dialogs to not show anything on Windows.

src/eric7/PipInterface/Pip.py file | annotate | diff | comparison | revisions
--- a/src/eric7/PipInterface/Pip.py	Fri Sep 02 16:07:11 2022 +0200
+++ b/src/eric7/PipInterface/Pip.py	Sat Sep 03 17:16:33 2022 +0200
@@ -991,13 +991,8 @@
         if envName:
             interpreter = self.getVirtualenvInterpreter(envName)
             if interpreter:
-                from . import pipdeptree
-
-                with open(pipdeptree.__file__, "r") as f:
-                    content = f.read()
                 args = [
-                    "-c",
-                    content,
+                    os.path.join(os.path.dirname(__file__), "pipdeptree.py"),
                     "--json-tree",
                 ]
                 if localPackages:
@@ -1048,13 +1043,9 @@
         if envName:
             interpreter = self.getVirtualenvInterpreter(envName)
             if interpreter:
-                from . import piplicenses
 
-                with open(piplicenses.__file__, "r") as f:
-                    content = f.read()
                 args = [
-                    "-c",
-                    content,
+                    os.path.join(os.path.dirname(__file__), "piplicenses.py"),
                     "--from",
                     "mixed",
                     "--with-system",

eric ide

mercurial