无法更新到Spyder 4.0.0


17

我在Windows 10(64位)下。

我尝试了几次,用Anaconda Prompt和Anaconda Navigator更新Spyder 4.0.0。失败了 我卸载了Anaconda,然后重新安装了它。

然后我以管理员身份运行Anaconda Prompt并执行:

conda update spyder

Spyder的版本是3.3.6。我尝试了以下命令:

conda install spyder=4.0.0

提示返回:

Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: |
Found conflicts! Looking for incompatible packages.
This can take several minutes.  Press CTRL-C to abort.
Finding conflicts:   0%|                                                                       | 0/360 [00:00<?, ?it/s]|Examining hpack:  42%|█████████████████████████▌                                   | 151/360 [00:00<00:00, 1468.80it/s]/Examining jupyter_core:  56%|██████████████████████████████▍                       | 203/360 [00:00<00:00, 1468.80it/-
- mparing specs that have this dependency:   0%|                                                | 0/20 [00:00<?, ?it/\
Examining jupyter_core:  57%|██████████████████████████████▌                       | 204/360 [00:20<00:00, 1468.80it/s]|| mparing specs that have this dependency:  10%|████                                    | 2/20 [00:18<02:47,  9.32s/i/ |
Comparing specs that have this dependency:  55%|█████████████████████▍                 | 11/20 [01:07<00:55,  6.16s/i-
Examining tbb:  73%|███████████████████████████████████████████████▎                 | 262/360 [02:35<01:19,  1.24it/s]-Examining jedi:  81%|███████████████████████████████████████████████████▉            | 292/360 [02:35<00:54,  1.24it/- \
Examining jupyter_client:  90%|████████████████████████████████████████████████▍     | 323/360 [06:03<04:23,  7.12s/i\ \
Comparing specs that have this dependency:   7%|██▋                                     | 1/15 [00:10<02:27, 10.51s/i-
Comparing specs that have this dependency:  13%|█████▎                                  | 2/15 [00:21<02:19, 10.73s/i/ |
Comparing specs that have this dependency:  27%|██████████▋                             | 4/15 [00:31<01:25,  7.77s/i\ \
Finding conflict paths:   0%|                                                                    | 0/7 [00:00<?, ?it// -
Comparing specs that have this dependency:  73%|████████████████████████████▌          | 11/15 [01:21<00:29,  7.40s/i\ |
Finding shortest conflict path for jupyter_client[version='>=4.2']:  67%|██████████▋     | 4/6 [00:10<00:01,  1.35it/| -
Comparing specs that have this dependency:  80%|███████████████████████████████▏       | 12/15 [01:34<00:23,  7.91s/i- |
failed                                                                                                                 /
                                                                                                                       \
UnsatisfiableError: The following specifications were found to be incompatible with a past
explicit spec that is not an explicit spec in this operation (spyder):

  - spyder=4.0.0

The following specifications were found to be incompatible with each other:



Package jedi conflicts for:
spyder=4.0.0 -> python-language-server[version='>=0.31.2,<0.32.0'] -> jedi[version='>=0.14.1,<0.16']
jedi
jupyterlab_server -> notebook -> ipykernel -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
anaconda==2019.10 -> jedi==0.15.1[build='py37_0|py36_0|py27_0']
ipython -> jedi[version='>=0.10']
qtconsole -> ipykernel[version='>=4.1'] -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
_ipyw_jlab_nb_ext_conf -> ipywidgets -> ipython[version='>=4.0.0'] -> jedi[version='>=0.10']
jupyter_console -> ipython -> jedi[version='>=0.10']
spyder-kernels -> ipykernel -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
widgetsnbextension -> notebook[version='>=4.4.1'] -> ipykernel -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
jupyterlab -> notebook[version='>=4.3.1'] -> ipykernel -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
jupyter -> ipykernel -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
spyder=4.0.0 -> qtconsole[version='>=4.6.0'] -> ipykernel[version='>=4.1'] -> ipython[version='>=5.0'] -> jedi[version='>=0.10']
ipywidgets -> ipython[version='>=4.0.0'] -> jedi[version='>=0.10']
notebook -> ipykernel -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
ipykernel -> ipython[version='>=4.0'] -> jedi[version='>=0.10']
anaconda==2019.10 -> spyder==3.3.6=py27_0 -> jedi[version='>=0.10|>=0.9']
spyder=4.0.0 -> jedi=0.14.1
Package jupyter_client conflicts for:
_ipyw_jlab_nb_ext_conf -> jupyterlab -> notebook[version='>=4.3.1'] -> nbconvert -> jupyter_client[version='>=4.2']
widgetsnbextension -> notebook[version='>=4.4.1'] -> nbconvert -> jupyter_client[version='>=4.2']
jupyterlab -> notebook[version='>=4.3.1'] -> nbconvert -> jupyter_client[version='>=4.2']
ipywidgets -> widgetsnbextension[version='>=3.3.0,<3.4.0'] -> notebook[version='>=4.4.1'] -> jupyter_client[version='>=5.2.0|>=5.3.1|>=5.3.4']
jupyterlab_server -> notebook -> jupyter_client[version='>=5.2.0|>=5.3.1|>=5.3.4']
anaconda==2019.10 -> ipykernel==4.10.0=py27_0 -> jupyter_client[version='>=4.1|>=5.2.0|>=5.2.3|>=5.3.1']
jupyter -> ipykernel -> jupyter_client[version='>=4.1|>=4.2|>=5.2.0|>=5.3.1|>=5.3.4']
ipywidgets -> widgetsnbextension[version='>=3.3.0,<3.4.0'] -> notebook[version='>=4.4.1'] -> nbconvert -> jupyter_client[version='>=4.2']
spyder=4.0.0 -> qtconsole[version='>=4.6.0'] -> ipykernel[version='>=4.1'] -> jupyter_client
jupyterlab -> notebook[version='>=4.3.1'] -> jupyter_client[version='>=5.2.0|>=5.3.1|>=5.3.4']
spyder=4.0.0 -> nbconvert -> jupyter_client[version='>=4.1|>=4.2|>=5.3.4']
ipywidgets -> ipykernel[version='>=4.5.1'] -> jupyter_client
anaconda==2019.10 -> jupyter_client==5.3.3[build='py27_1|py36_1|py37_1']
spyder-kernels -> ipykernel -> jupyter_client
jupyter_console -> jupyter_client
spyder-kernels -> jupyter_client[version='>=5.2.3|>=5.3.4']
notebook -> nbconvert -> jupyter_client[version='>=4.2']
jupyter_client
notebook -> jupyter_client[version='>=5.2.0|>=5.3.1|>=5.3.4']
nbconvert -> jupyter_client[version='>=4.2']
_ipyw_jlab_nb_ext_conf -> ipywidgets -> ipykernel[version='>=4.5.1'] -> jupyter_client[version='>=5.2.0|>=5.3.1|>=5.3.4']
jupyterlab_server -> notebook -> nbconvert -> jupyter_client[version='>=4.2']
widgetsnbextension -> notebook[version='>=4.4.1'] -> jupyter_client[version='>=5.2.0|>=5.3.1|>=5.3.4']
ipykernel -> jupyter_client
qtconsole -> ipykernel[version='>=4.1'] -> jupyter_client
qtconsole -> jupyter_client[version='>=4.1']
Package jupyter_core conflicts for:
anaconda==2019.10 -> jupyter_core==4.5.0=py_0
spyder=4.0.0 -> nbconvert -> jupyter_client[version='>=4.2'] -> jupyter_core[version='>=4.6.0']
nbconvert -> jupyter_client[version='>=4.2'] -> jupyter_core[version='>=4.6.0']
jupyterlab -> notebook[version='>=4.3.1'] -> jupyter_core[version='>=4.4.0|>=4.6.0']
ipywidgets -> ipykernel[version='>=4.5.1'] -> jupyter_client -> jupyter_core[version='>=4.4.0|>=4.6.0']
anaconda-project -> anaconda-client -> nbformat[version='>=4.4.0'] -> jupyter_core
jupyter_core
anaconda-navigator -> anaconda-client[version='>=1.6'] -> nbformat[version='>=4.4.0'] -> jupyter_core
jupyter -> notebook -> jupyter_core[version='>=4.4.0|>=4.6.0']
_ipyw_jlab_nb_ext_conf -> jupyterlab -> notebook[version='>=4.3.1'] -> jupyter_core[version='>=4.4.0|>=4.6.0']
spyder-kernels -> jupyter_client[version='>=5.2.3'] -> jupyter_core[version='>=4.6.0']
widgetsnbextension -> notebook[version='>=4.4.1'] -> jupyter_core[version='>=4.4.0|>=4.6.0']
notebook -> jupyter_core[version='>=4.4.0|>=4.6.0']
ipywidgets -> nbformat[version='>=4.2.0'] -> jupyter_core
anaconda-client -> nbformat[version='>=4.4.0'] -> jupyter_core
nbformat -> jupyter_core
jupyter_console -> jupyter_client -> jupyter_core[version='>=4.6.0']
anaconda==2019.10 -> jupyter_client==5.3.3=py27_1 -> jupyter_core[version='>=4.4.0']
qtconsole -> jupyter_core
ipykernel -> jupyter_client -> jupyter_core[version='>=4.6.0']
spyder=4.0.0 -> nbconvert -> jupyter_core
jupyter_client -> jupyter_core[version='>=4.6.0']
nbconvert -> jupyter_core
jupyterlab_server -> notebook -> jupyter_core[version='>=4.4.0|>=4.6.0']
qtconsole -> jupyter_client[version='>=4.1'] -> jupyter_core[version='>=4.6.0']
Package spyder-kernels conflicts for:
spyder=4.0.0 -> spyder-kernels[version='>=1.8.1,<2.0.0']
spyder-kernels
anaconda==2019.10 -> spyder-kernels==0.5.2[build='py37_0|py36_0|py27_0']
anaconda==2019.10 -> spyder==3.3.6=py27_0 -> spyder-kernels[version='>=0.5.0,<1']
Package qtconsole conflicts for:
anaconda==2019.10 -> qtconsole==4.5.5=py_0
jupyter -> qtconsole
anaconda==2019.10 -> jupyter==1.0.0=py27_7 -> qtconsole[version='>=4.2']
spyder=4.0.0 -> qtconsole[version='>=4.6.0']
qtconsole

启动Anaconda Navigator时,Spyder版本仍为3.3.6。

我缺少什么才能受益于Spyder的最新版本?

编辑1:

当我尝试使用Anaconda Navigator时,它说:

无法在此环境中安装spyder 4.0.0

它提出了要安装的其他环境,但我希望对Spyder进行更新,而不要在其他地方安装。

编辑2: 我成功地将conda更改为4.6,但出现了两个错误:

FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\brichard\\AppData\\Local\\Continuum\\anaconda3\\Menu\\spyder_shortcut.jsodone

和:

CondaError: Cannot link a source that does not exist. C:\Users\brichard\AppData\Local\Continuum\anaconda3\Scripts\conda.exe 
Running `conda clean --packages` may resolve your problem.

conda clean --packages命令无济于事,因为执行后会出现相同的错误。


尝试使用conda install -c anaconda spyder
Ajay

@obiwankenobi,它返回了Spyder(3.3.6)的相同版本
Basile

Answers:


30

这里是Spyder维护者)其他用户报告您需要运行

conda update anaconda

然后

conda install spyder=4

成功更新到版本4。

希望能有所帮助。


1
这是什么意思 ?Solving environment: failed with initial frozen solve. Retrying with flexible solve. Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
巴西利勒

这些只是警告消息。不要注意他们。
卡洛斯·科尔多瓦

它没有用,命令命令成功运行,但Spyder不是4
Basile

1
这对我有用。
Beckenbaur93

1
即使在删除了很多spyder可执行文件之后,该过程仍如何保持3.6的安装。从anaconda导航器中,我无法获得3.6以上的任何版本。这是行得通的:1)从导航器中,卸载spyder 2)安装spyder,将其神奇地拉到4.0.1
andy

5

我使用了以下内容:

conda update anaconda

然后

conda update spyder
conda install spyder=4.0.1

成功更新到版本4.0.1


2

我也无法在Win x64上将Spyder更新到v4.0.0;但我找到了解决方案。

关于我的设置的一句话:我使用Miniconda和conda环境conda-forge作为顶部频道和设置channel_priority: strict(根据conda- forge 的建议)。这使conda 考虑conda-forge渠道中的软件包。

我为我的活动环境禁用了严格的通道优先级(conda v5.0 + [ conda-forge ] 将来可能会不受欢迎):

conda config --env --set channel_priority disabled

现在终于可以将Spyder更新到v4.0.0:

conda update spyder

似乎conda需要以下软件包(从defaults/ anaconda渠道获取):- blas1.0,jupyter_client-5.3.4,pluggy-0.13.1,python-3.7.5,scipy-1.3.2。 jedi已降级(0.15.1-py37_0-> 0.14.1-py37_0)。

仅供参考:我还考虑了以下其他答案:


顺便说一句:仅使用Spyder v4.0.0(及其依赖项)创建一个新的干净环境也仅适用于严格的通道优先级disabled(使用时conda-forge),也就是说,这不起作用

conda create -n spyder -c conda-forge --strict-channel-priority spyder=4.0.0

如果您从具有以下环境的环境中执行以下操作,它也将不起作用strict channel_priority

conda create -n spyder -c conda-forge spyder=4.0.0

(你需要disablechannel_priority第一个)


我按照您的要求,但是没有用,如何打开Spyder?
巴西利勒

您是否conda-forge添加了频道?如果不是这样,它可以帮助:conda config --env --add channels conda-forge; 然后尝试再次更新。我只是从Windows的“开始”菜单中打开Spyder
BottleNick,

我收到了这个新问题:ERROR conda.core.link:_execute(568): An error occurred while installing package 'defaults::autopep8-1.4.4-py_0'. CondaError: Cannot link a source that does not exist. C:\Users\brichard\AppData\Local\Continuum\anaconda3\Scripts\conda.exe
巴西利勒(Basile)

2

对于那些试图升级到Spyder 4并在Windows 10中使用conda环境的人来说,这里只是一个补充说明。我想使用Spyder 4,但同时也得到了Spyder内部的错误,提示它找不到spyder内核。不管(1)是否在新环境或基本环境中安装Spyder,以及(2)即使随后通过conda安装了spyder-kernel,都不会发生这种情况。

我试图遵循上面给出的建议,并且已经通过Windows安装程序安装了Anaconda,但是当我尝试

conda update anaconda

它在基本环境中找不到Anaconda。所以我还是使用conda安装了Anaconda(即使这对我来说似乎是递归的)

conda install anaconda

之后,我可以通过以下方式更新Anaconda:

conda update anaconda

一旦做到这一点,我就可以在基本环境(已经安装)上运行Spyder 4,并且我得到了一个可用的Ipython内核。

因此,我可以从基本环境中打开Spyder,并使用Spyder菜单,工具->首选项-> Python解释器,可以设置想要的conda环境,例如C:\ Users \\ Anaconda3 \ envs \ myenv \ python.exe

然后,要允许Spyder在我要使用的conda环境中创建一个Ipython内核,我必须在该环境中安装spyder内核,因此,我启动了一个新的Anaconda提示符,并:

conda activate myenv

conda install spyder-kernels

最后,回到Spyder,重新启动内核(Ctrl +。)。这为我提供了一个运行良好的Ipython内核,然后查看Spyder窗口底部的状态栏,可以看到我处于myenv环境中。

因此,现在我可以使用Spyder IDE(从基本环境启动它),但可以在先前创建的conda环境中工作。它还避免了将完整的Spyder安装到我创建的每个环境中(但确实意味着必须在每个环境中安装spyder内核)。

我知道这是一个很长的评论,但是在解决这个确切的问题之前,我花了相当长的时间环顾四周,因此我希望它对也面临同样问题的其他人很有用。


1

我设法解决了这个问题,这可能是由于在同一个根环境中保留了太多软件包所致。首先,尝试降级conda,正如最近在conda存储库上的建议中所建议的那样:

conda install -n root conda=4.6

之后,再给Spyder一个机会:

conda install spyder=4.0.0

如果那没有用,我相信您可以像以前一样解决问题-通过创建一个新环境(例如使用Anaconda Navigator)并直接从那里安装Spyder 4.0.0


1

我刚在PC上安装了Anaconda。因此,在Anaconda命令提示符中执行以下操作对我来说很有用。Spyder及其它许多版本已更新至4.0.0。

conda update anaconda

0

我尝试时遇到了同样的问题

conda install spyder=4.1.2

然后我做了下面的工作!

conda config --set allow_conda_downgrades true
conda install conda=4.6.14
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.