mysqlclient-1.4.6-cp38-cp38-win32.whl改成
mysqlclient-1.4.6-cp38-cp38m-win32.whl
image.png
2.出现问题的原因,pip不支持对应的版本
>>> from pip._internal.pep425tags import get_supported
>>> print(get_supported())
[('cp36', 'cp36m', 'win_amd64'), ('cp36', 'none', 'win_amd64'), ('py3', 'none', 'win_amd64'), ('cp36', 'none', 'any'), ('cp3', 'none', 'any'), ('py36', 'none', 'any'), ('py3', 'none', 'any'), ('py35', 'none', 'any'), ('py34', 'none', 'any'), ('py33', 'none', 'any
'), ('py32', 'none', 'any'), ('py31', 'none', 'any'), ('py30', 'none', 'any')]
pip 支持('cp38', 'cp38m', 'win32')
而下载回来的文件是mysqlclient-1.4.6-cp38-cp38-win32.whl
cp38-cp38-win32不在支持的范围内.
需要改成pip支持的cp38-cp38m-win32
image.png
import wheel.pep425tags as w
print(w.get_supported(''))
[('cp38', 'cp38', 'win_amd64'), ('cp38', 'none', 'win_amd64'), ('cp38', 'none', 'any')]
3.实际结果
(venv) C:\Users\花菜\Downloads\mysqlclient-python-1.3.14>pip install "C:\Users\花菜\Downloads\mysqlclient-1.4.6-cp38-cp38-win32.whl"
mysqlclient-1.4.6-cp38-cp38-win32.whl is not a supported wheel on this platform.
(venv) C:\Users\花菜\Downloads\mysqlclient-python-1.3.14>pip install "C:\Users\花菜\Downloads\mysqlclient-1.4.6-cp38-cp38m-win32.whl"
Processing c:\users\花菜\downloads\mysqlclient-1.4.6-cp38-cp38m-win32.whl
Installing collected packages: mysqlclient
Successfully installed mysqlclient-1.4.6
网友评论