【问题标题】:Installing Spyder in a conda environment在 conda 环境中安装 Spyder
【发布时间】:2022-01-02 22:17:06
【问题描述】:

我使用 Anaconda 提示符为qcodes 创建了一个conda 环境,如下所示,

conda create -n qcodes
conda activate qcodes
conda config --add channels conda-forge --env
conda config --set channel_priority strict --env
conda install qcodes

由于 Spyder 不在我尝试安装的环境中,

conda install spyder

这给了我以下错误,

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.

ResolvePackageNotFound:
  - python=3.1

我尝试使用更新conda

conda update conda

得到了……

PackageNotInstalledError: Package is not installed in prefix.
  prefix: C:\Users\nr2-roberts\.conda\envs\qcodes
  package name: conda

conda update anaconda 也一样

有人知道这里发生了什么吗?

【问题讨论】:

  • 好像你有 python 3.10 qcodes env。 conda(默认频道或 conda-forge 频道)上没有(目前)Spyder 包与 Python 3.10 兼容。我建议你重新创建你的环境,但是在做 conda install qcodes 时做 conda install qcodes python=3.9
  • @DanielAlthviz 就是这样,如果你想把你的评论作为问题的答案,我可以点赞并接受它,以便其他人在未来更容易找到
  • 当然@DrBwts,完成

标签: anaconda conda spyder virtual-environment


【解决方案1】:

您的 qcodes 环境中似乎有 python 3.10。 conda 上没有(目前)与 Python 3.10 兼容的 Spyder 包(既不在默认通道上,也不在 conda-forge 通道上)。我建议你重新创建你的环境,但是在做 conda install qcodes 时做 conda install qcodes python=3.9

【讨论】:

    猜你喜欢
    • 2020-10-28
    • 2021-07-30
    • 2019-01-04
    • 2021-06-22
    • 2019-02-01
    • 2020-10-21
    • 2019-08-18
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多