Select to view content in your preferred language

Spyder IDE no longer works after upgrade to ArcGIS Pro 2.5

10210
35
02-08-2020 11:16 AM
JohnHuillery1
Regular Contributor

Error:

Traceback (most recent call last):
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\Scripts\jupyter-nbextension-script.py", line 6, in <module>
from notebook.nbextensions import main
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\__init__.py", line 25, in <module>
from .nbextensions import install_nbextension
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 28, in <module>
from ipython_genutils.py3compat import string_types, cast_unicode_py2
ModuleNotFoundError: No module named 'ipython_genutils.py3compat'
Traceback (most recent call last):
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\Scripts\jupyter-nbextension-script.py", line 6, in <module>
from notebook.nbextensions import main
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\__init__.py", line 25, in <module>
from .nbextensions import install_nbextension
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 28, in <module>
from ipython_genutils.py3compat import string_types, cast_unicode_py2
ModuleNotFoundError: No module named 'ipython_genutils.py3compat'

DEBUG menuinst_win32:__init__(199): Menu: name: 'Anaconda${PY_VER} ${PLATFORM}', prefix: 'C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3', env_name: 'arcgispro-py3', mode: 'user', used_mode: 'user'
DEBUG menuinst_win32:create(323): Shortcut cmd is C:\Users\JHUILL~1\AppData\Local\Temp\_MEI144042\pythonw.exe, args are ['C:\\Users\\JHUILL~1\\AppData\\Local\\Temp\\_MEI144042\\cwp.py', '"C:\\Program Files\\ArcGIS\\Pro\\bin\\Python\\envs\\arcgispro-py3"', '"C:\\Program Files\\ArcGIS\\Pro\\bin\\Python\\envs\\arcgispro-py3\\pythonw.exe"', '"C:\\Program Files\\ArcGIS\\Pro\\bin\\Python\\envs\\arcgispro-py3\\Scripts\\spyder-script.py"']
DEBUG menuinst_win32:create(323): Shortcut cmd is C:\Users\JHUILL~1\AppData\Local\Temp\_MEI144042\python.exe, args are ['C:\\Users\\JHUILL~1\\AppData\\Local\\Temp\\_MEI144042\\cwp.py', '"C:\\Program Files\\ArcGIS\\Pro\\bin\\Python\\envs\\arcgispro-py3"', '"C:\\Program Files\\ArcGIS\\Pro\\bin\\Python\\envs\\arcgispro-py3\\python.exe"', '"C:\\Program Files\\ArcGIS\\Pro\\bin\\Python\\envs\\arcgispro-py3\\Scripts\\spyder-script.py"', '--reset']
Traceback (most recent call last):
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\runpy.py", line 183, in _run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\runpy.py", line 109, in _get_module_details
__import__(pkg_name)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\__init__.py", line 3, in <module>
from . import (features, geoanalytics, geocoding, geometry,
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\features\__init__.py", line 28, in <module>
from . import enrich_data
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\features\enrich_data.py", line 10, in <module>
import arcgis.network as network
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\network\__init__.py", line 7, in <module>
from ._layer import NetworkLayer, NetworkDataset, ClosestFacilityLayer, ServiceAreaLayer, RouteLayer, NAJob
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\network\_layer.py", line 8, in <module>
from arcgis.mapping import MapImageLayer
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\mapping\__init__.py", line 8, in <module>
from ._types import WebMap, WebScene, MapImageLayer, MapImageLayerManager, VectorTileLayer, OfflineMapAreaManager, PackagingJob
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\mapping\_types.py", line 19, in <module>
from arcgis.widgets import MapView
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\widgets\__init__.py", line 2, in <module>
from arcgis.widgets._mapview import MapView
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\widgets\_mapview.py", line 15, in <module>
from ipywidgets import widgets
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\__init__.py", line 25, in <module>
from .widgets import *
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\widgets\__init__.py", line 4, in <module>
from .widget import Widget, CallbackDispatcher, register, widget_serialization
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\widgets\widget.py", line 18, in <module>
from ipykernel.comm import Comm
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\__init__.py", line 1, in <module>
from .manager import *
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\manager.py", line 15, in <module>
from .comm import Comm
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\comm.py", line 9, in <module>
from ipykernel.kernelbase import Kernel
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\kernelbase.py", line 19, in <module>
from jupyter_client.session import utcnow as now
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\jupyter_client\session.py", line 56, in <module>
from zmq.eventloop.ioloop import IOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\zmq\eventloop\__init__.py", line 3, in <module>
from zmq.eventloop.ioloop import IOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\zmq\eventloop\ioloop.py", line 78, in <module>
while _IOLoop.configurable_default() is not _IOLoop:
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\tornado\ioloop.py", line 328, in configurable_default
from tornado.platform.asyncio import AsyncIOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\tornado\platform\asyncio.py", line 34, in <module>
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
AttributeError: module 'asyncio' has no attribute 'WindowsSelectorEventLoopPolicy'
Traceback (most recent call last):
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\Scripts\jupyter-nbextension-script.py", line 10, in <module>
sys.exit(main())
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\jupyter_core\application.py", line 267, in launch_instance
return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\traitlets\config\application.py", line 664, in launch_instance
app.start()
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 988, in start
super(NBExtensionApp, self).start()
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\jupyter_core\application.py", line 256, in start
self.subapp.start()
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 716, in start
self.install_extensions()
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 695, in install_extensions
**kwargs
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 211, in install_nbextension_python
m, nbexts = _get_nbextension_metadata(module)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 1122, in _get_nbextension_metadata
m = import_item(module)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\traitlets\utils\importstring.py", line 42, in import_item
return __import__(parts[0])
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\__init__.py", line 3, in <module>
from . import (features, geoanalytics, geocoding, geometry,
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\features\__init__.py", line 28, in <module>
from . import enrich_data
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\features\enrich_data.py", line 10, in <module>
import arcgis.network as network
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\network\__init__.py", line 7, in <module>
from ._layer import NetworkLayer, NetworkDataset, ClosestFacilityLayer, ServiceAreaLayer, RouteLayer, NAJob
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\network\_layer.py", line 8, in <module>
from arcgis.mapping import MapImageLayer
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\mapping\__init__.py", line 8, in <module>
from ._types import WebMap, WebScene, MapImageLayer, MapImageLayerManager, VectorTileLayer, OfflineMapAreaManager, PackagingJob
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\mapping\_types.py", line 19, in <module>
from arcgis.widgets import MapView
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\widgets\__init__.py", line 2, in <module>
from arcgis.widgets._mapview import MapView
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\widgets\_mapview.py", line 15, in <module>
from ipywidgets import widgets
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\__init__.py", line 25, in <module>
from .widgets import *
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\widgets\__init__.py", line 4, in <module>
from .widget import Widget, CallbackDispatcher, register, widget_serialization
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\widgets\widget.py", line 18, in <module>
from ipykernel.comm import Comm
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\__init__.py", line 1, in <module>
from .manager import *
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\manager.py", line 15, in <module>
from .comm import Comm
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\comm.py", line 9, in <module>
from ipykernel.kernelbase import Kernel
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\kernelbase.py", line 19, in <module>
from jupyter_client.session import utcnow as now
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\jupyter_client\session.py", line 56, in <module>
from zmq.eventloop.ioloop import IOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\zmq\eventloop\__init__.py", line 3, in <module>
from zmq.eventloop.ioloop import IOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\zmq\eventloop\ioloop.py", line 78, in <module>
while _IOLoop.configurable_default() is not _IOLoop:
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\tornado\ioloop.py", line 328, in configurable_default
from tornado.platform.asyncio import AsyncIOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\tornado\platform\asyncio.py", line 34, in <module>
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
AttributeError: module 'asyncio' has no attribute 'WindowsSelectorEventLoopPolicy'
Traceback (most recent call last):
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\Scripts\jupyter-nbextension-script.py", line 10, in <module>
sys.exit(main())
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\jupyter_core\application.py", line 267, in launch_instance
return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\traitlets\config\application.py", line 664, in launch_instance
app.start()
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 988, in start
super(NBExtensionApp, self).start()
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\jupyter_core\application.py", line 256, in start
self.subapp.start()
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 896, in start
self.toggle_nbextension_python(self.extra_args[0])
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 872, in toggle_nbextension_python
logger=self.log)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 483, in enable_nbextension_python
logger=logger)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 380, in _set_nbextension_state_python
m, nbexts = _get_nbextension_metadata(module)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\notebook\nbextensions.py", line 1122, in _get_nbextension_metadata
m = import_item(module)
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\traitlets\utils\importstring.py", line 42, in import_item
return __import__(parts[0])
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\__init__.py", line 3, in <module>
from . import (features, geoanalytics, geocoding, geometry,
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\features\__init__.py", line 28, in <module>
from . import enrich_data
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\features\enrich_data.py", line 10, in <module>
import arcgis.network as network
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\network\__init__.py", line 7, in <module>
from ._layer import NetworkLayer, NetworkDataset, ClosestFacilityLayer, ServiceAreaLayer, RouteLayer, NAJob
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\network\_layer.py", line 8, in <module>
from arcgis.mapping import MapImageLayer
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\mapping\__init__.py", line 8, in <module>
from ._types import WebMap, WebScene, MapImageLayer, MapImageLayerManager, VectorTileLayer, OfflineMapAreaManager, PackagingJob
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\mapping\_types.py", line 19, in <module>
from arcgis.widgets import MapView
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\widgets\__init__.py", line 2, in <module>
from arcgis.widgets._mapview import MapView
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\widgets\_mapview.py", line 15, in <module>
from ipywidgets import widgets
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\__init__.py", line 25, in <module>
from .widgets import *
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\widgets\__init__.py", line 4, in <module>
from .widget import Widget, CallbackDispatcher, register, widget_serialization
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipywidgets\widgets\widget.py", line 18, in <module>
from ipykernel.comm import Comm
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\__init__.py", line 1, in <module>
from .manager import *
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\manager.py", line 15, in <module>
from .comm import Comm
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\comm\comm.py", line 9, in <module>
from ipykernel.kernelbase import Kernel
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\ipykernel\kernelbase.py", line 19, in <module>
from jupyter_client.session import utcnow as now
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\jupyter_client\session.py", line 56, in <module>
from zmq.eventloop.ioloop import IOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\zmq\eventloop\__init__.py", line 3, in <module>
from zmq.eventloop.ioloop import IOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\zmq\eventloop\ioloop.py", line 78, in <module>
while _IOLoop.configurable_default() is not _IOLoop:
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\tornado\ioloop.py", line 328, in configurable_default
from tornado.platform.asyncio import AsyncIOLoop
File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\tornado\platform\asyncio.py", line 34, in <module>
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
AttributeError: module 'asyncio' has no attribute 'WindowsSelectorEventLoopPolicy'


(arcgispro-py3) C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3>

Tags (2)
35 Replies
DaleJackan
Emerging Contributor

I found some hints as to what might be going on here: Troubleshooting Guide and FAQ · spyder-ide/spyder Wiki · GitHub 

The best process I found for fixing this issue is as follows, hopefully this will work for you. When issuing any of the commands always wait until a new command prompt comes up before entering the next command, this can take a while. Even if it looks like you have an error just move forward with what I have written to type.

1. within ArcGIS Pro go to the Python Package Manager>Manage Environments

Create a new cloned environment from the first environment in the list and then close ArcGIS Pro after it has been created.

2. Open up the ArcGIS Pro Command Prompt and type: conda update python

3. Type:

conda update qtconsole

-this should yield not found

4. Type:

conda install qtconsole

5. Type:

conda install spyder

When I originally did this in a different order I found the qtconsole would not work and caused spyder to fail. The solution appears to be to install qtconsole prior to installing spyder. If I install spyder and let it automatically install qtconsole as a dependency it fails. There could be some sort of incorrect dependency issue with qtconsole versioning or something when letting spyder do it. There is a possibility that this environment will result in different package versions than what some tools may use in ArcGIS Pro. If you find a tool failing within ArcGIS Pro and the tool is python based then you might need to go back into the python package manager and set the environment back to the default in order to get it to run.

If you are still having an issue type:

jupyter qtconsole

If this results in an error then I think the problem is still related to qtconsole.

Good luck!

0 Kudos
DanPatterson_Retired
MVP Emeritus

There is a documented issue with qtconsole, which is why I use --no-pin so that spyder can install the version it wants.

In any event "patching" a previous install is not worth the wasted time.

  • Download the *.exe, unpack it to get the *.msi and *.cab.
  • Wipe (aka rename) anything Esri names on your computer (c:\user\you\local... App is a good place to start, but a File Explorer search and a coffee will get them allP)
  • install pro
  • switch to conda and do your installs from there
    • conda install blah_blah --no-pin --dry-run
    • if good, remove --dry-run from the above

And my personal preference is not to clone at all because I have full rights on my computer.  The worse that can happen is I get another coffee and go back over my steps, with the advantage that I have already unpacked the *.exe

ZacharyHart
Honored Contributor

I tried what Dale Jackan‌ suggested. I did this from a fresh clone from a clean 2.5 install. I can't even up update python via Conda! Dan Patterson

0 Kudos
DaleJackan
Emerging Contributor

I will try to help, but please forgive me for not trying to read through everything. This is my understanding of things. You have virtual environments created within conda itself and then virtual environments created by ArcGIS Pro using conda. The normal conda environment has access to normal conda repositories. The ArcGIS Pro conda environment has access to ESRI conda repositories and therefore different versions and requirements/dependencies. You are kind of working with one ArcGIS Pro virtual environment and two different repositories. Understand sometimes if you update you may either break dependencies or in some cases fix dependencies, I have experienced both. I create my environment within arcgis pro and then do all of my updates within ArcGIS Pro. After that if spyder does not work then I open conda console/navigator up to my ArcGIS Pro virtual environment I just created and try to run spyder to see what errors show up. Once I see the errors I try to guess what packages might need to be updated and start updating them from the console. Only make one change at a time and test spyder after every change. I can't claim it always works and in some cases spyder eventually works after ESRI updates some packages only in their repository, which you have to update from within ArcGIS Pro. I can say Dan Patterson's advice to use: ``` conda install blah_blah --no-pin --dry-run ```  did prove useful to run the more current spyder. Also, understand sometimes when you need to install other packages within ArcGIS Pro their dependencies could revert your spyder or break it because they rely on the same packages, but different versions.  The issues all seem to be about package dependencies breaking and trying to figure out which ones broke and what versions are needed. Good luck, I wish I could say I had a concrete answer.

DanDeegan
Regular Contributor

"The issues all seems to be about package dependencies breaking and trying to figure out which ones broke and what versions are needed."

And we install spyder using software that manages dependencies.

And there was much rejoicing.

yaaaaaaaay.

DaleJackan
Emerging Contributor

Understand it's because two different systems (standard conda, ArcGIS Pro conda) with their own repositories are trying to manage one ArcGIS Pro virtual environment. That said yes installing packages within ArcGIS Pro has broken package dependencies for it's own packages. As for conda it doesn't know about the required versioning for various packages within ArcGIS Pro it only understands it's own packages and repositories, or at least it appears that way.

0 Kudos
DanPatterson
MVP Esteemed Contributor

If you update python, you will break being able to work with _arcgisscripting and several other dlls.  You need to stick with python 3.6.x if you intend to use any arc* functionality.


... sort of retired...
0 Kudos
DanPatterson_Retired
MVP Emeritus

see my post above yours, for some reason they are switched

never mind, back to normal now

0 Kudos
DanDeegan
Regular Contributor

I had spyder 4 running before 2.5. Now I can't get it to work at all. I used to use the anaconda navigator to get it. I am about to give up and go back to VSCode and jupyter notebooks. I love Spyder's variable explorer but it is such a PITA to install and keep alive that I am starting to see it as not worth it.

0 Kudos
DanPatterson_Retired
MVP Emeritus

Did you patch anaconda navigator to get it to find spyder?

In any event

Choose your environment ( I install in the base and not a clone) and start conda from the Windows start menu

It is masked as the Python Interactive Terminal.... but it is just a shortcut to C:\arc_pro\bin\Python\Scripts\propy.ba

where C:\arc_pro is your install folder

conda install spyder --no-pin

Then I navigate to find the spyder-script.py file and create a shortcut for the desktop

Target:

C:\arc_pro\bin\Python\envs\arcgispro-py3\pythonw.exe "C:\arc_pro\bin\Python\envs\arcgispro-py3\Scripts\spyder-script.py"

Start in:

C:\arc_pro\bin\Python\envs\arcgispro-py3\Scripts

where C:\arc_pro\ is arcgis pro install folder

and    ...envs\arcgispro-py3  is the environment I installed it.  If you are using a clone, you will have to activate it and install it there

0 Kudos