最新的"pip"失败,并显示“需要dist-info的setuptools> = 0.8" [英] Latest 'pip' fails with "requires setuptools >= 0.8 for dist-info"

查看:94
本文介绍了最新的"pip"失败,并显示“需要dist-info的setuptools> = 0.8"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用pip的最新(1.5)版本,尝试更新多个软件包时出现错误.例如,sudo pip install -U pytz会导致失败,

Using the recent (1.5) version of pip, I get an error when attempting to update several packages. For example, sudo pip install -U pytz results in failure with:

Wheel installs require setuptools >= 0.8 for dist-info support.
pip's wheel support requires setuptools >= 0.8 for dist-info support.

我不理解此消息(我有setuptools 2.1)或如何处理.

I don't understand this message (I have setuptools 2.1) or what to do about it.

日志中有关此错误的异常信息:

Exception information from the log for this error:

Exception information:
Traceback (most recent call last):
  File "/Library/Python/2.7/site-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/Library/Python/2.7/site-packages/pip/commands/install.py", line 230, in run
    finder = self._build_package_finder(options, index_urls, session)
  File "/Library/Python/2.7/site-packages/pip/commands/install.py", line 185, in _build_package_finder
    session=session,
  File "/Library/Python/2.7/site-packages/pip/index.py", line 50, in __init__
    self.use_wheel = use_wheel
  File "/Library/Python/2.7/site-packages/pip/index.py", line 89, in use_wheel
    raise InstallationError("pip's wheel support requires setuptools >= 0.8 for dist-info support.")
InstallationError: pip's wheel support requires setuptools >= 0.8 for dist-info support.

推荐答案

这对我有用:

sudo pip install setuptools --no-use-wheel --upgrade

请注意它是sudo的用法

Note it's usage of sudo

更新

在窗口上,您只需以管理员身份执行pip install setuptools --no-use-wheel --upgrade.在unix/linux中,sudo命令用于提升权限.

On window you just need to execute pip install setuptools --no-use-wheel --upgrade as an administrator. In unix/linux, sudo command is for elevating permissions.

更新

此问题似乎已在1.5.1中修复.

This appears to have been fixed in 1.5.1.

这篇关于最新的"pip"失败,并显示“需要dist-info的setuptools> = 0.8"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆