I am using python and conda within ArcGIS Pro 2.2, but am running into some problems with virtual environments. I have cloned a copy of the Arcgis Pro environment (hereafter clone). When I activate clone in the home folder for the original ArcGIS environment (C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3
), the python executable is located at C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\python.exe
. However, if I activate clone in any other location, the clone looks to the clone's home folder and activates that version of python (located at C:\Users\RDCERWAW\AppData\Local\conda\conda\envs\gee\python.exe
). This is causing problems because import arcpy works when I run the python.exe
located at .\arcgispro-py3, but not when using the python.exe located at .\gee
. Even when I modify the PYTHONPATH to include the path the .\arcgispro-py3\python.exe
, the other location is accessed first. I could always start the clone in the .\argispro-py3
folder, but unfortunately spyder keeps looking back at .\gee
.
Does anyone know how to code conda so that it look in a specific location first?