【问题标题】:Installing pip on Zorin在 Zorin 上安装 pip
【发布时间】:2017-06-19 09:27:49
【问题描述】:

我正在尝试在 Zorin 8 上安装 pip。但是当我使用 sudo apt-get install python3-pip 时,我收到以下错误

Err http://ubuntu.mirrors.pair.com/archive/ saucy/main libexpat1-dev amd64 2.1.0-4
  404  Not Found

Err http://ubuntu.mirrors.pair.com/archive/ saucy/main libpython3-dev amd64 3.3.2-14ubuntu1
  404  Not Found

Err http://ubuntu.mirrors.pair.com/archive/ saucy/main python3-dev amd64 3.3.2-14ubuntu1
  404  Not Found

Err http://ubuntu.mirrors.pair.com/archive/ saucy/main python3-setuptools all 0.6.37-1ubuntu1
  404  Not Found

Err http://ubuntu.mirrors.pair.com/archive/ saucy/universe python3-pip all 1.4.1-2
  404  Not Found

Failed to fetch http://ubuntu.mirrors.pair.com/archive/pool/main/e/expat/libexpat1-dev_2.1.0-4_amd64.deb  404  Not Found

Failed to fetch http://ubuntu.mirrors.pair.com/archive/pool/main/p/python3-defaults/libpython3-dev_3.3.2-14ubuntu1_amd64.deb  404  Not Found

Failed to fetch http://ubuntu.mirrors.pair.com/archive/pool/main/p/python3-defaults/python3-dev_3.3.2-14ubuntu1_amd64.deb  404  Not Found

Failed to fetch http://ubuntu.mirrors.pair.com/archive/pool/main/d/distribute/python3-setuptools_0.6.37-1ubuntu1_all.deb  404  Not Found

Failed to fetch http://ubuntu.mirrors.pair.com/archive/pool/universe/p/python-pip/python3-pip_1.4.1-2_all.deb  404  Not Found

E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

请提出解决方案。在尝试安装 pip 之前,我曾尝试过 sudo apt-get upgrade。我的工作站上安装了 python 3.3.2+ 版本。

【问题讨论】:

    标签: python linux pip


    【解决方案1】:

    如果您已经拥有 Python,那么它可能已经附带了 pip,只需将 pip 的文件夹添加到 %path%(或 Zorin 用于路径索引的任何环境变量)。

    但是,如果你真的确定你没有pip,但你有Python,那么你应该看看here,它包含安装@987654327的所有二进制数据@。

    另外,你确定你有 Python 吗? 如果你没有它,看看你是否可以通过 Python's official website 下载 Zorin 可能会很有用。另外,据我研究,我发现 Zorin 运行 Debian 的 .deb packages,这意味着您可能会寻找 Python .deb 包。

    编辑:也许我应该在评论中说这个,但是,嘿,不合适,这已经帮助 C:

    【讨论】:

    • 我使用了get-pip.py 文件并使用sudo 安装了pip。在安装 numpy 和 pandas 包时,我必须使用 sudo pip2 install numpy,即我必须使用 pip2 而不是 pip。这样做表明已经满足要求,即安装了 numpy。但是,当我尝试运行我的代码时,它显示“没有名为 numpy 的模块”
    • 您是否碰巧同时安装了 Python 2 和 3?检查[python folder]/lib中是否有numpy相关的文件夹。
    • 我的系统上有 python3 和 python2。我只能为 python2 安装 numpy。我使用 python 2 运行我的代码,它运行良好。谢谢。我在安装其他软件包时遇到了同样的问题。我想我的系统无法找到包。您认为这是由于系统安装不正确造成的吗?
    • 您似乎需要指定 Python 2 或 Python 3 的完整 pip 路径。或者将其附加到 %path% 或您的操作系统的文件夹索引环境变量中。
    猜你喜欢
    • 2017-07-09
    • 2016-11-04
    • 2013-07-07
    • 2021-09-16
    • 2021-03-26
    • 2018-06-13
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多