安装 python 个包在 md5 中有问题

installing python packages have issue in md5

我正在使用 Windows,当我想要安装软件包时出现以下错误:

pip install django
Requirement already satisfied (use --upgrade to upgrade): django in c:\python27\lib\site-packages

C:\code\Djangotest\amar-e-simples-master>pip install django --upgrade
Collecting django
  Downloading Django-1.9.7-py2.py3-none-any.whl (6.6MB)
    6% |#                               | 399kB 3.3MB/s eta 0:00:02
THESE PACKAGES DO NOT MATCH THE HASHES FROM THE REQUIREMENTS FILE. If you have updated the package versions, please update the hashes. Otherwise, examine the package contents carefully; someone may have tampered with them.
    django from https://pypi.python.org/packages/e6/f9/154e1460c4a95c90ab28ead50314161ea2c4016f3561033b41f687f0a76d/Django-1.9.7-py2.py3-none-any.whl#md5=5224b6f237a9e46a84fc0f9921f678ae:
        Expected md5 5224b6f237a9e46a84fc0f9921f678ae
             Got        f603e16057383b3ad12d8bda84492fbb

如何处理这个问题(在 windows 中)?

如果出现pip这样的错误:error: no such option: --hash,您使用的Pip版本太旧,请使用以下命令升级:

$ pip install --upgrade pip

在 Windows 上推荐的命令是:

python -m pip install --upgrade pip

更新后,如果再次出现此错误, 在 upgrade/install:

时使用“--no-cache-dir
pip --no-cache-dir install YOUR-PACKAGENAME

pip --no-cache-dir install --upgrade YOUR-PACKAGENAME

散列值不同的一个很好的原因是,如果您使用的平台不在现有散列值范围内,用于有轮子的包。