Cannot install spyder

hi,

newcomer to this excellent distro...

cannot install spyder, however, can anyone help?

❯ yay -S spyder                                                                         100%   433.3 Mbps  ─╯
resolving dependencies...
looking for conflicting packages...

Packages (44) python-argh-0.26.2-8  python-astroid-2.4.2-4  python-atomicwrites-1.4.0-3  python-babel-2.8.1-2
              python-cloudpickle-1.2.2-5  python-diff-match-patch-20200713-3  python-docutils-0.16-4
              python-future-0.18.2-5  python-helpdev-0.7.1-3  python-imagesize-1.2.0-4
              python-intervaltree-3.1.0-3  python-isort-5.6.4-3  python-jeepney-0.6.0-4
              python-jsonrpc-server-0.4.0-3  python-keyring-21.5.0-3  python-language-server-0.36.1-1
              python-lazy-object-proxy-1.5.2-2  python-mccabe-0.6.1-7  python-numpydoc-1.1.0-3
              python-pathtools-0.1.2-9  python-pluggy-0.13.1-4  python-pylint-2.6.0-3  python-pytz-2020.4-3
              python-qdarkstyle-2.8.1-3  python-qtawesome-0.6.0-5  python-qtconsole-4.7.3-3
              python-secretstorage-3.3.0-1  python-sip-4.19.24-4  python-snowballstemmer-2.0.0-6
              python-sortedcontainers-2.3.0-3  python-sphinx-3.3.1-2  python-sphinx-alabaster-theme-0.7.12-6
              python-sphinxcontrib-applehelp-1.0.2-3  python-sphinxcontrib-devhelp-1.0.2-3
              python-sphinxcontrib-htmlhelp-1.0.3-3  python-sphinxcontrib-jsmath-1.0.1-6
              python-sphinxcontrib-qthelp-1.0.3-3  python-sphinxcontrib-serializinghtml-1.1.4-3
              python-spyder-kernels-1.10.0-3  python-ujson-4.0.1-3  python-watchdog-0.10.4-1
              python-wrapt-1.12.1-4  python-wurlitzer-2.0.0-3  spyder-4.1.5-3

Total Installed Size:  101.47 MiB

:: Proceed with installation? [Y/n] 
(44/44) checking keys in keyring                                      [--------------------------------------] 100%
(44/44) checking package integrity                                    [--------------------------------------] 100%
(44/44) loading package files                                         [--------------------------------------] 100%
(44/44) checking for file conflicts                                   [--------------------------------------] 100%
error: failed to commit transaction (conflicting files)
python-pytz: /usr/lib/python3.9/site-packages/pytz/__init__.py exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/__pycache__/__init__.cpython-39.pyc exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/__pycache__/exceptions.cpython-39.pyc exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/__pycache__/lazy.cpython-39.pyc exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/__pycache__/reference.cpython-39.pyc exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/__pycache__/tzfile.cpython-39.pyc exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/__pycache__/tzinfo.cpython-39.pyc exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/exceptions.py exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/lazy.py exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/reference.py exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/tzfile.py exists in filesystem
python-pytz: /usr/lib/python3.9/site-packages/pytz/tzinfo.py exists in filesystem
Errors occurred, no packages were upgraded.
error installing repo packages

The issue lies within the python-pytz package, and has probably happened because you have run sudo pip install at some point.

You can overwrite the existing files - assuming you didn’t put them there yourself and know better - with:

sudo pacman -S spyder --overwrite="usr/lib/python3.9/site-packages/pytz/*"
5 Likes

wow what a terrific response time…
thank you it installed but describes missing dependency spyder_kernels

also what does the line below mean regarding .pac* files? (sorry i’m new, never had these on manjaro or endeavour os)

(5/6) Checking for .pacnew and .pacsave files…
.pac* files found:
/etc/nohang/nohang-desktop.conf.pacnew
/etc/systemd/homed.conf.pacnew
Please check and merge
(6/6) Updating the desktop file MIME type cache…

I assume that’s related to the package python-spyder-kernels. This implies your package lists are out-of-date, or your mirror is out-of-date. First, try:

sudo pacman -Syu

and if that doesn’t help then refresh your mirror list (and try the above again).

https://wiki.archlinux.org/index.php/Pacman/Pacnew_and_Pacsave

3 Likes

thanks again for your help jonathon...

still surprised that spyder won't run due to the dependency problem. i wonder if anyone else is experiencing.

mirror refresh unfortunately didn't help.

thoughts?

Ya well that's going to happen, if you don't install your packages the correct way (using the pacman command , not pip).

3 Likes

Can you post some steps someone can use to replicate the problem you’re seeing? e.g. which commands will show the error?

1 Like

Clarification: I did not use pip, I only used the pacman command sudo pacman -Sy spyder

The application starts, but has a window message upon startup specifying the library conflicts.

Incidentally, I installed manjaro also and the error is replicated. But the consequence is different; spyder in manjaro allowed me to work after closing the error window, whereas in garuda it crashes.

not sure why this is not being reported, but it appears reproducible.

Great. If you can provide some replication steps then someone might be able to help.

Also keep in mind that this thread is marked as Solved, so this might be a different issue and so should be in a new thread.