diff --git a/scripts/debugging_panel.py b/scripts/debugging_panel.py index d80bc32..94f491f 100644 --- a/scripts/debugging_panel.py +++ b/scripts/debugging_panel.py @@ -1,3 +1,11 @@ +import os +import subprocess +pythonExec = os.environ["ProgramFiles"]+ r"\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\python.exe" +result = subprocess.run([pythonExec, "-m", "pip", "install", "--upgrade", "--ignore-installed", "specklepy==2.17.17"], capture_output=True, text=True, shell=True, timeout=1000) +result = subprocess.run([pythonExec, "-m", "pip", "install", "--upgrade", "--ignore-installed", "panda3d==1.10.11"], capture_output=True, text=True, shell=True, timeout=1000) +result = subprocess.run([pythonExec, "-m", "pip", "install", "--upgrade", "--ignore-installed", "PyQt5==5.15.9"], capture_output=True, text=True, shell=True, timeout=1000) + + from arcpy._mp import ArcGISProject, Map, Layer as arcLayer import arcpy diff --git a/speckle_arcgis_installer/conda_clone_activate.py b/speckle_arcgis_installer/conda_clone_activate.py index dd72278..030d18b 100644 --- a/speckle_arcgis_installer/conda_clone_activate.py +++ b/speckle_arcgis_installer/conda_clone_activate.py @@ -181,7 +181,14 @@ def installDependencies(pythonExec: str, pkgName: str, pkgVersion: str): print(f"Installing {pkgName} to {pythonExec}") # subprocess_call( [pythonExec, "-m", "pip", "uninstall", f"{pkgName}"]) subprocess_call( - [pythonExec, "-m", "pip", "install", f"{pkgName}=={pkgVersion}"] + [ + pythonExec, + "-m", + "pip", + "install", + "--ignore-installed", + f"{pkgName}=={pkgVersion}", + ] ) elif pkgName == "panda3d": import panda3d @@ -191,7 +198,14 @@ def installDependencies(pythonExec: str, pkgName: str, pkgVersion: str): ): print(f"Installing {pkgName} to {pythonExec}") subprocess_call( - [pythonExec, "-m", "pip", "install", f"{pkgName}=={pkgVersion}"] + [ + pythonExec, + "-m", + "pip", + "install", + "--ignore-installed", + f"{pkgName}=={pkgVersion}", + ] ) elif pkgName == "PyQt5": import PyQt5 @@ -201,7 +215,14 @@ def installDependencies(pythonExec: str, pkgName: str, pkgVersion: str): ): print(f"Installing {pkgName} to {pythonExec}") subprocess_call( - [pythonExec, "-m", "pip", "install", f"{pkgName}=={pkgVersion}"] + [ + pythonExec, + "-m", + "pip", + "install", + "--ignore-installed", + f"{pkgName}=={pkgVersion}", + ] ) except Exception as e: print(f"{pkgName} not installed")