PIP: “Cannot uninstall 'ipython'. It is a

2019-01-06 22:11发布

I'm trying to install Spyder via PIP but I get the error:

Cannot uninstall 'ipython'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.

4条回答
做个烂人
2楼-- · 2019-01-06 22:48

For Python 2:

pip install --upgrade --force-reinstall --no-cache-dir Spyder

For Python 3:

pip3 install --upgrade --force-reinstall --no-cache-dir Spyder
查看更多
相关推荐>>
3楼-- · 2019-01-06 22:54

Just solved with:

sudo apt-get remove ipython
查看更多
Juvenile、少年°
4楼-- · 2019-01-06 23:05

Some of the solutions listed may work, but this one solved my issue with distutils installed packages.

sudo apt-get remove python-ipython

Depending on what type of package it is, you will need to provide the "python-" for python packages.

Edit: However, if this still does not solve your question, you might want to consider downgrading pip to an earlier version as pip 10 does not allow removal of distutils packages

sudo -H pip install pip==9.0.1
sudo pip uninstall ipython

Thank you for the comment, as I am looking to improve how I can help people.

查看更多
放荡不羁爱自由
5楼-- · 2019-01-06 23:10

You can upgrade ipython without uninstall the old version

sudo -H pip install --ignore-installed -U ipython
查看更多
登录 后发表回答