eric7/PipInterface/Pip.py

branch
eric7
changeset 9016
6f079c524e99
parent 9003
6bc210cd5726
child 9056
af7c8c7b7c62
child 9111
4ac66b6c33a4
--- a/eric7/PipInterface/Pip.py	Sun Apr 03 17:23:31 2022 +0200
+++ b/eric7/PipInterface/Pip.py	Mon Apr 04 17:43:43 2022 +0200
@@ -210,7 +210,7 @@
             )
             if not venvName:
                 # fall back to interpreter used to run eric7
-                return sys.executable
+                return Globals.getPythonExecutable()
         
         interpreter = (
             ericApp().getObject("VirtualEnvManager")
@@ -352,7 +352,9 @@
         if not venvName:
             return False
         
-        if self.getVirtualenvInterpreter(venvName) == sys.executable:
+        if self.getVirtualenvInterpreter(venvName) in (
+            sys.executable, Globals.getPythonExecutable()
+        ):
             upgradePyQt = self.__checkUpgradePyQt(packages)
             upgradeEric = self.__checkUpgradeEric(packages)
             if upgradeEric or upgradePyQt:
@@ -961,7 +963,7 @@
                     args.append("--reverse")
                 
                 proc = QProcess()
-                proc.start(sys.executable.replace("w.exe", ".exe"), args)
+                proc.start(Globals.getPythonExecutable(), args)
                 if proc.waitForStarted(15000) and proc.waitForFinished(30000):
                     output = str(proc.readAllStandardOutput(),
                                  Preferences.getSystem("IOEncoding"),

eric ide

mercurial