Description
After upgrading ArcGIS Pro to version 2.2, any of the following three errors occur:
- Python window shows "Failed to Initialize Python Interpreter"
- Upon starting ArcGIS Pro, the following message appears: "Failed to load system tools... Space Time Pattern Mining Tools.pyt." Additionally, no geoprocessing toolboxes appear in the Geoprocessing tab.
- Upon opening the Space Time Pattern Mining toolbox, the dialog returns the error, "Tool has failed to open."
Cause
The following four files are missing from the folder C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3:
- python.exe
- python3.dll
- python36.dll
- pythonw.exe
The use of ArcGIS Pro's Python Package Manager (as well as Conda from the command line) to install Python packages can trigger the updating of Python from 3.6.2 (shipped with ArcGIS Pro 2.1) to 3.6.6. When ArcGIS Pro updates, the package files are of a higher version than what is shipped with ArcGIS Pro 2.2 (Python 3.6.5). In this situation, the update behavior is to mark these files to not install with ArcGIS Pro 2.2.
Solution or Workaround
There are multiple methods for resolving this problem, depending on the system used. If ArcGIS Pro is not yet upgraded from 2.1 to 2.2, this issue can be avoided entirely by following the "ArcGISPro.msi" sequence.
Using ArcGISPro.msi:
- Uninstall ArcGIS Pro 2.1.
- Rename the folder '\ArcGIS\Pro' to 'ArcGIS\Pro21_leftovers'.
- Reinstall ArcGIS Pro 2.2.
Using ArcGISPro.msi's "repair" functionality:
- Get the latest version of the Pro .msi (http://links.esri.com/pro/download/current).
- Rename the \pkgs folder found in 'C:\Program Files\ArcGIS\Pro\bin\python' from 'pkgs' to 'pkgs_leftovers'.
- Run the .msi and select the Repair option.
In Conda:
- Click the Windows Start button.
- Navigate to ArcGIS > (ArcGIS Pro) > Python Command Prompt.
- Launch the Python Command Prompt in Administrator mode (In Windows 10, hold Ctrl-Shift and left-click the app).
- Delete C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\conda-meta\python-3.6.*.json.
Note:
This may be ...python-3.6.5-?.json or ...python-3.6.6-?.json, where '?' is a unique identifier.
- Run the following command:
conda install python==3.6.5 --no-deps
- Rename the \pkgs folder found in 'C:\Program Files\ArcGIS\Pro\bin\python' from 'pkgs' to 'pkgs_leftovers'.