pip安裝模塊或者某個包出現錯誤時

錯誤描述:

 ImportError: The 'packaging' package is required; normally this is bundled with this package so if you get this warning, consult the packager of your distribution.

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\zyn\AppData\Local\Temp\pip-install-l2lr3u71\sklearn\

此時,通過pip list查看安裝的setuptools的版本,如果不是19.2則卸載重裝即可

解決辦法步驟:

輸入pip uninstall setuptools

pip install setuptools==19.2

然後重新安裝原本要安裝的模塊或者包即可

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章