I can't recall how many times I've cloned python environments for ArcGIS pro and then added packages to them, but, this one takes the cake.
Using the ArcGIS pro package mis-manager I install spyder 3.something and spyder kernel 1.9.2 and upon launching spyder I get the 'Spyder has encountered an internal problem' window, telling me:
plugin = mod.PLUGIN_CLASS(self)
AttributeError: '_ModuleMock' object has no attribute 'PLUGIN_CLASS'
Well cowboy, this isn't my first rodeo (see _ModuleMock object has to attribute 'PLUGIN CLASS' for example) so I open a python command window in my new clone and run
conda update spyder
But, after that the sh## storm really starts. I get another internal problem window with so many issues, I can't believe my eyes:
Here is the full list:
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\editor\widgets\codeeditor.py", line 1393, in handle_hover_response
self._request_hover_clicked)
TypeError: CodeEditor.sig_display_object_info[str, bool].emit(): argument 1 has unexpected type 'list'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\EnvClones\arcgispro26\lib\logging\__init__.py", line 994, in emit
msg = self.format(record)
File "C:\EnvClones\arcgispro26\lib\logging\__init__.py", line 840, in format
return fmt.format(record)
File "C:\EnvClones\arcgispro26\lib\logging\__init__.py", line 577, in format
record.message = record.getMessage()
File "C:\EnvClones\arcgispro26\lib\logging\__init__.py", line 338, in getMessage
msg = msg % self.args
ValueError: incomplete format
Call stack:
File "C:\EnvClones\arcgispro26\Scripts\spyder-script.py", line 10, in <module>
sys.exit(main())
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\app\start.py", line 219, in main
mainwindow.main()
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\app\mainwindow.py", line 3763, in main
mainwindow = run_spyder(app, options, args)
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\app\mainwindow.py", line 3679, in run_spyder
app.exec_()
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\completion\plugin.py", line 302, in <lambda>
lambda: self.receive_timeout(req_id))
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\completion\plugin.py", line 136, in receive_timeout
self.howto_send_to_codeeditor(req_id)
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\completion\plugin.py", line 177, in howto_send_to_codeeditor
self.skip_and_send_to_codeeditor(req_id)
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\completion\plugin.py", line 205, in skip_and_send_to_codeeditor
self.gather_and_send_to_codeeditor(request_responses)
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\completion\plugin.py", line 273, in gather_and_send_to_codeeditor
response_instance.handle_response(req_type, responses)
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\editor\widgets\codeeditor.py", line 1019, in handle_response
handler(params)
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\editor\widgets\codeeditor.py", line 1406, in handle_hover_response
self.log_lsp_handle_errors("Error when processing hover")
File "C:\EnvClones\arcgispro26\lib\site-packages\spyder\plugins\editor\widgets\codeeditor.py", line 1050, in log_lsp_handle_errors
logger.error('%', 1, stack_info=True)
Message: '%'
Arguments: (1,)
I've wiped my previous environments (I'll remember what other package dependencies I need to fix tomorrow when my over night scripts fail). I get the same lengthy list of issues if I do a straight conda install for spyder.
And to think everything was going so well today too....
Suggestions? I guess I could uninstall ArcGIS Pro entirely, and reinstall, but then what's the point in 'upgrading'?
or
(I never know which of you is the right one...)
Joe Borgione We are both wondering why you tried installing Spyder 3? (and was the new look post fly fishing?)
I installed Spyder in the base/main environment and the only issue I had was that Matplotlib doesn't work in ArcGIS Pro notebooks.
But that isn't a real problem since
https://community.esri.com/people/danretired/blog/2020/08/01/notebooks-in-spyder
do a really good job, unless you want to see a map... but why would you want to see a map in an ArcGIS Pro Notebook, when you can just look at the map... anyway, we digress .
I suspect it is the IPython widgets (or dependencies) conflicting with what is not in Pro 2.6.
I haven't tracked the issues down with Matplotlib, but ipython is used by Pro, Matplotlib and spyder and the latest version of Spyder uses upgraded ipython and the widgets.
So in short, install Spyder 4.14 ... in your clone if you must
apparently others are having clone issues
https://community.esri.com/thread/257533-trying-to-clone-python-environment-in-arcgis-pro-26
I have to say also I am running into issues. Full environment deletes and re-installs are not necessarily clearing up the issue.
Upgrading is becoming a pain with these Pro updates. I think for advanced users we might be on the verge to suspecting every update disrupting conda at our firm.
David... you might want to chime in here... python, conda, packages whatever
https://community.esri.com/thread/257737-timeline-for-python-upgrade
On my end I am seeing verification errors upon cloning, and I had to do a complete deletion of my previous conda environments to get a working clone.
(arcgispro-py3) C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3>conda env list
# conda environments:
#
arcgispro-py3 * C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3
root C:\Program Files\ArcGIS\Pro\bin\Python
(arcgispro-py3) C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3>conda create --name geoscipy --clone arcgispro-py3
Source: C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3
Destination: C:\Users\dwasserman\AppData\Local\ESRI\conda\envs\geoscipy
Packages: 141
Files: 19CondaVerificationError: The package for backcall located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\backcall-0.1.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/backcall/__pycache__/__init__.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for backcall located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\backcall-0.1.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/backcall/__pycache__/_signatures.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for backcall located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\backcall-0.1.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/backcall/__pycache__/backcall.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for et_xmlfile located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\et_xmlfile-1.0.1-py36h3d2d736_0
appears to be corrupted. The path 'Lib/site-packages/et_xmlfile/__pycache__/__init__.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for et_xmlfile located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\et_xmlfile-1.0.1-py36h3d2d736_0
appears to be corrupted. The path 'Lib/site-packages/et_xmlfile/__pycache__/xmlfile.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for et_xmlfile located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\et_xmlfile-1.0.1-py36h3d2d736_0
appears to be corrupted. The path 'Lib/site-packages/et_xmlfile/tests/__pycache__/__init__.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for et_xmlfile located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\et_xmlfile-1.0.1-py36h3d2d736_0
appears to be corrupted. The path 'Lib/site-packages/et_xmlfile/tests/__pycache__/common_imports.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for et_xmlfile located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\et_xmlfile-1.0.1-py36h3d2d736_0
appears to be corrupted. The path 'Lib/site-packages/et_xmlfile/tests/__pycache__/helper.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for et_xmlfile located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\et_xmlfile-1.0.1-py36h3d2d736_0
appears to be corrupted. The path 'Lib/site-packages/et_xmlfile/tests/__pycache__/test_incremental_xmlfile.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for send2trash located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\send2trash-1.5.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/send2trash/__pycache__/__init__.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for send2trash located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\send2trash-1.5.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/send2trash/__pycache__/compat.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for send2trash located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\send2trash-1.5.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/send2trash/__pycache__/exceptions.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for send2trash located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\send2trash-1.5.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/send2trash/__pycache__/plat_gio.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for send2trash located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\send2trash-1.5.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/send2trash/__pycache__/plat_osx.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for send2trash located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\send2trash-1.5.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/send2trash/__pycache__/plat_other.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for send2trash located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\send2trash-1.5.0-py36_0
appears to be corrupted. The path 'Lib/site-packages/send2trash/__pycache__/plat_win.cpython-36.pyc'
specified in the package manifest cannot be found.CondaVerificationError: The package for simplegeneric located at C:\Program Files\ArcGIS\Pro\bin\Python\pkgs\simplegeneric-0.8.1-py36_2
appears to be corrupted. The path 'Lib/site-packages/__pycache__/simplegeneric.cpython-36.pyc'
specified in the package manifest cannot be found.
I am in the process of checking if this clone works, and it looks like it might. My process to "fix" my issues were:
1. Delete the Python Conda Folder with Admin access, copy out some open source conda environments out before hand
2. Delete arcgispro-py3
3. Repair arcgispro-py3
4. Reclone arcgispro-py3 - still get verification errors, but arcpy seems to work
5. Further testing (will fill in later)
Both Dans- yes the new look is post fly fishing; actually on what I affectionatley call the 'Mighty' Weber River not far from home. The old me was really the young me, when I used do a lot of back country skiing.
At any rate, using conda for the install instead of Pro, I did install 4.1.4 spyder but ended up with the same laundry list of issues. (I have seen the other post you mention; now there are two data points and we can draw a line...)
Since you don't clone you are adding packages right to the default env with conda, right? And you haven't see any issues as I describe? Scheduled for a fish day in the morning but I'll get righ back at it day after tomorrow and maybe scrap the clone. (Prepping for retirement: My wife said the other day, "Just think how good your casting will be once your'e retired!"... Love that woman to pieces!)
Oh, this: why would you want to see a map in an ArcGIS Pro Notebook, when you can just look at the map. Been wondering the same thing!
So in short, install Spyder 4.14 ... in your clone if you must
Okay- here is what I ended up doing; I wiped the the clone, and re-cloned the default that pro 2.6 provides Then, using conda, not arcgis pro, I install spyder using:
conda install spyder=4.1.3
No errors. Yet...
Just don't use matplotlib in ArcGIS Pro notebooks, you can't make graphs. If you want to get adventurous
https://community.esri.com/people/danretired/blog/2020/08/01/notebooks-in-spyder
if you need notebooks but not maps
PS you installed 4.1.3 upgrade! 4.1.4, unless that was a finger slip
Nope... I didn't install 4.1.4 because of the issues I've encountered Sticking with what I know works with arcgis pro, and hoping it all works with arcgis pro 2.6