ERROR: Cannot uninstall 'greenlet'. It is a distutils installed project and thus we cannot accuratel

pip安装allenmlp的时候,出现如下错误:

ERROR: Cannot uninstall 'greenlet'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.

原因distutils安装的包缺少相应的metadatapip不能完全卸载。
解决方法:distutils没有提供相关的卸载命令,直接找到包的位置,删除相应的文件即可,比如

mv ~/anaconda3/lib/python3.6/site-packages/greenlet* /tmp/

之后再安装即可。

参考

  • https://github.com/pypa/pip/issues/5247
  • https://github.com/pypa/pip/pull/3389
  • https://github.com/blockstack/blockstack-core/issues/504

猜你喜欢

转载自blog.csdn.net/feifei3211/article/details/100890369
今日推荐