conda搜索找不到可以在conda cloud上找到的包

Conda search can't find package that can be found on conda cloud

例如,我可以在 anaconda 云上找到 gxx_linux-64,但是当我使用 conda search 搜索它时:

conda search -c conda-forge gxx_linux-64

它告诉我

Loading channels: done
No match found for: gxx_linux-64. Search: *gxx_linux-64*

PackagesNotFoundError: The following packages are not available from current channels:

  - gxx_linux-64

Current channels:

  - https://conda.anaconda.org/conda-forge/osx-64
  - https://conda.anaconda.org/conda-forge/noarch
  - https://repo.anaconda.com/pkgs/main/osx-64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/r/osx-64
  - https://repo.anaconda.com/pkgs/r/noarch

To search for alternate channels that may provide the conda package you're
looking for, navigate to

    https://anaconda.org

and use the search bar at the top of the page.

Conda 将搜索限制在 noarch 和平台特定的频道子目录中。在这种情况下,频道信息表明在osx-64平台上搜索运行,而包裹显然是linux-64 构建,因此找不到它的原因。

可以通过包含这是频道规范来专门搜索其他子目录。也就是说,无论从哪个平台搜索,都应该找到包

conda search -c conda-forge/linux-64 gxx_linux-64

或者,使用完整的 MatchSpec 语法

conda search conda-forge::gxx_linux-64[subdir=“linux-64”]

但是,请注意,此软件包不兼容 osx-64