我是靠谱客的博主 温暖大米,这篇文章主要介绍whl文件安装失败解决方法,现在分享给大家,希望可以做个参考。

在cmd命令行下安装whl文件:

pip install ***.whl

***是文件名,也可以是路径+文件名

 

报错:***.whl is not a supported wheel on this platform.

原因一:文件和python不匹配(文件名中cm后面的数字和python版本应该匹配)

查看python版本(Shell):

ADM64

import pip._internal
print(pip._internal.pep425tags.get_supported())

WIN32

import pip
print(pip.pep425tags.get_supported())

如果输入不对会出现:AttributeError: module 'pip' has no attribute 'pep425tags'

输入成功可进入python目录,查看支持的版本

Python 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit (AMD64)] on win32
Type "copyright", "credits" or "license()" for more information.
>>> import pip._internal
>>> print(pip._internal.pep425tags.get_supported())
[('cp37', 'cp37m', 'win_amd64'), ('cp37', 'none', 'win_amd64'), ('py3', 'none', 'win_amd64'), ('cp37', 'none', 'any'), ('cp3', 'none', 'any'), ('py37', 'none', 'any'), ('py3', 'none', 'any'), ('py36', 'none', 'any'), ('py35', 'none', 'any'), ('py34', 'none', 'any'), ('py33', 'none', 'any'), ('py32', 'none', 'any'), ('py31', 'none', 'any'), ('py30', 'none', 'any')]
>>> 

下载对应版本,安装whl文件

二、如果版本没有错,那就是wheel没有安装

在cmd命令窗口输入:pip install wheel

提示Successful后安装成功,在找到whl文件安装

 

 

 

最后

以上就是温暖大米最近收集整理的关于whl文件安装失败解决方法的全部内容,更多相关whl文件安装失败解决方法内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(57)

评论列表共有 0 条评论

立即
投稿
返回
顶部