I have had to reinstall ArcGIS Pro 2.0 and have attempted to recreate an Anaconda environment, but am running into some problems. When I create a new environment from the initial ArcGIS Pro environment, I can install packages using pip, but then when I try to load them from within the cloned environment, the modules can't be found. Here are the steps I performed.

  1. Open Command Prompt as provided by ArcGIS Pro (not in the GUI)
  2. conda create --clone old --name new
  3. activate new
  4. pip install package
  5. python -c "import package"

This results in an error message. Within the new environment, sys.executable returns the old environment. If I provide the hard path the python executable in the new environment, I can load the package. But this behavior doesn't seem right. I am assuming that when I try to open python within an Anaconda environment it should use the environment's python version.


3 Answers 3


You may just want to move up to later version of ArcGIS Pro.

Your expectation matches the 2.2 behavior nicely.

2.2 session below (sanitized for noise).

(arcgispro-py3) C:\Program Files\ArcGIS\Pro\bin\Python\Scripts>conda create --clone arcgispro-py3 --name new
Source:      C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3
Destination: C:\Users\user\AppData\Local\ESRI\conda\envs\new
Packages: 98
Files: 23
- Validating: ok

(arcgispro-py3) C:\Program Files\ArcGIS\Pro\bin\Python\Scripts>activate new

(new) C:\Program Files\ArcGIS\Pro\bin\Python\Scripts>pip install bs4
Collecting bs4
Collecting beautifulsoup4 (from bs4)
  Using cached https://files.pythonhosted.org/packages/fe/62/720094d06cb5a92cd4b3aa3a7c678c0bb157526a95c4025d15316d594c4b/beautifulsoup4-4.6.1-py3-none-any.whl
Installing collected packages: beautifulsoup4, bs4
Successfully installed beautifulsoup4-4.6.1 bs4-0.0.1
You are using pip version 9.0.3, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

(new) C:\Program Files\ArcGIS\Pro\bin\Python\Scripts>python -c "import bs4;print(bs4.__version__)"

Posting the fix I found,

typed into cmd at the conda install location

conda create -k --clone arcgispro-py3 --name test

the -k runs the command in the insecure ssl mode

Here is the reference I used:



The issue is that when ArcGIS Pro creates a clone of an environment, the clone still links back to the original environment's python executable. So when you install packages via pip in the new environment, they are not available to that environment. However, if you start spyder from within the new environment, it does link to the new environment's python executable and you can load pip-installed packages. Not sure why, but seems to be the way ArcGIS wants to structure their clones.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.