lyn*_*ynx 5 spyder software-installation 18.04
我想在 Ubuntu 18.04 上安装最新版本的 Spyder。我需要将 Spyder 更新到最新版本(spyder 3.3.2),因为版本 3.2.6 存在一些错误,例如变量资源管理器不显示变量。我不使用 Anaconda,也不想用 Anaconda 安装它。
当我尝试安装它时pip install -U spyder
出现以下错误:
Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: '/home/candan/.local/lib/python2.7/site-packages/QtPy-1.6.0.dist-info/METADATA'
Run Code Online (Sandbox Code Playgroud)
完整结果在这里:
candan@candan-HP-ProBook-470-G2:~$ pip install -U spyder
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
Collecting spyder
Using cached https://files.pythonhosted.org/packages/1b/ec/c8edcd40ff3af06cffa5bff1397ad63a3f5d34d36818f684d6e0f88fad44/spyder-3.3.2-py2-none-any.whl
Requirement already satisfied, skipping upgrade: qtpy>=1.5.0 in ./.local/lib/python2.7/site-packages (from spyder) (1.6.0)
No metadata found in ./.local/lib/python2.7/site-packages
Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: '/home/candan/.local/lib/python2.7/site-packages/QtPy-1.6.0.dist-info/METADATA'
candan@candan-HP-ProBook-470-G2:~$ pip --version
pip 19.0.1 from /usr/local/lib/python2.7/dist-packages/pip-19.0.1-py2.7.egg/pip (python 2.7)
candan@candan-HP-ProBook-470-G2:~$
Run Code Online (Sandbox Code Playgroud)
我还尝试通过下载包 Spyder 3.3.2 来手动安装它,但没有成功。
使用Ubuntu软件安装旧版本可以运行,但不是最新版本。如何正确安装最新版本的Sypder?
编辑:
对于Python 2.7,我使用以下命令进行更新:
pip install --upgrade spyder
Run Code Online (Sandbox Code Playgroud)
如果上述命令不起作用--user
,请在安装后添加。
对于Python 3:
python3 -m pip install --user --upgrade spyder
Run Code Online (Sandbox Code Playgroud)
您使用的是旧版本的 pip,但版本 19.0.1 可用。您应该考虑通过pip install --upgrade pip
命令进行升级。最新版本的 pip 需要最新稳定版本的 Python (Python 2.7.15rc1) 作为依赖项。要升级 pip,请运行以下命令:
sudo dpkg --remove --force-remove-reinstreq spyder spyder3
sudo apt-get update
sudo apt install python2.7
sudo -H pip install --upgrade pip pip3
Run Code Online (Sandbox Code Playgroud)
然后pip install -U --user spyder
就可以成功运行了。
安装 Spyder for Python 3.x 运行pip3 install -U --user spyder
请注意错误输出中的此消息DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
您应该使用pip3来安装spyder。
归档时间: |
|
查看次数: |
14605 次 |
最近记录: |