【问题标题】:Unable to Install Pip Package [duplicate]无法安装 Pip 包 [重复]
【发布时间】:2022-01-14 18:12:33
【问题描述】:

在 ubuntu 机器上,我无法对包执行 pip 安装 (genie)。

存在版本21.8

❯ pip3 install genie==
ERROR: Could not find a version that satisfies the requirement genie== 
(from versions: 1.0.0, 20.2, 20.4, 20.4.1, 20.5, 20.6, 20.6.1, 20.7, 20.8, 20.8.1b0, 20.8.1b1, 20.9, 20.10, 20.10.1b0, 20.12, 20.12.2, 21.1, 21.1.1, 21.1.2, 21.1.3, 21.2, 21.2.1, 21.2.2, 21.2.3, 21.3, 21.3.1, 21.3.2b1, 21.4, 21.5, 21.5.2, 21.6, 21.7, 21.8, 21.8.1, 21.8.2, 21.9, 21.10)

但如果我为它进行安装,我会得到:

$ pip install genie==21.8
ERROR: Could not find a version that satisfies the requirement genie==21.8 (from versions: 1.0.0)
ERROR: No matching distribution found for genie==21.8

如果我使用python3 pip install ...,问题也是一样的。从添加详细到 pip 安装我看到:

Skipping link: none of the wheel's tags match: cp39-cp39-macosx_10_16_x86_64: https://files.pythonhosted.org/packages/4f/27/6cc3037d4247a58d6e9b2fd8d7c987b7e326f9ff9c429609414e45a04f52/genie-21.10-cp39-cp39-macosx_10_16_x86_64.whl#sha256=fe83befdbe20d41b7c05ecd338bd277f813023be934be1ebb8b47df3deb89a16 (from https://pypi.org/simple/genie/) (requires-python:>=3.5)
  Skipping link: none of the wheel's tags match: cp39-cp39-manylinux1_x86_64: https://files.pythonhosted.org/packages/71/4b/45839aa84359c55fe6008dc6868f1928577edd786b832c7e67db9169e90c/genie-21.10-cp39-cp39-manylinux1_x86_64.whl#sha256=04b4155c066d530b48508989d3c1f074b4bb312cfb12d7a7fb8bd5698aad551e (from https://pypi.org/simple/genie/) (requires-python:>=3.5)
Given no hashes to check 0 links for project 'genie': discarding no candidates
ERROR: Could not find a version that satisfies the requirement genie==21.8 (from versions: 1.0.0)
Cleaning up...
Removed build tracker: '/tmp/pip-req-tracker-zz5x89tb'
ERROR: No matching distribution found for genie==21.8
Exception information:
Traceback (most recent call last):
  File "/home/dir/net-guide/venv/lib/python3.8/site-packages/pip/_internal/cli/base_command.py", line 186, in _main
    status = self.run(options, args)
  File "/home/dir/net-guide/venv/lib/python3.8/site-packages/pip/_internal/commands/install.py", line 357, in run
    resolver.resolve(requirement_set)
  File "/home/dir/net-guide/venv/lib/python3.8/site-packages/pip/_internal/legacy_resolve.py", line 177, in resolve
    discovered_reqs.extend(self._resolve_one(requirement_set, req))
  File "/home/dir/net-guide/venv/lib/python3.8/site-packages/pip/_internal/legacy_resolve.py", line 333, in _resolve_one
    abstract_dist = self._get_abstract_dist_for(req_to_install)
  File "/home/dir/net-guide/venv/lib/python3.8/site-packages/pip/_internal/legacy_resolve.py", line 281, in _get_abstract_dist_for
    req.populate_link(self.finder, upgrade_allowed, require_hashes)
  File "/home/dir/net-guide/venv/lib/python3.8/site-packages/pip/_internal/req/req_install.py", line 249, in populate_link
    self.link = finder.find_requirement(self, upgrade)
  File "/home/dir/net-guide/venv/lib/python3.8/site-packages/pip/_internal/index/package_finder.py", line 926, in find_requirement
    raise DistributionNotFound(
pip._internal.exceptions.DistributionNotFound: No matching distribution found for genie==21.8

有什么建议吗?

【问题讨论】:

    标签: python ubuntu pip


    【解决方案1】:
    python3 -m pip install genie==21.8
    

    在我的 Linux 机器上运行良好。也许指定你要使用的python3的版本,并通过-m调用pip。

    【讨论】:

    • 试过这个,没有运气。不过谢谢
    猜你喜欢
    • 2020-07-02
    • 1970-01-01
    • 2021-09-07
    • 2019-01-29
    • 1970-01-01
    • 1970-01-01
    • 2018-07-05
    • 2022-01-22
    相关资源
    最近更新 更多