【发布时间】:2018-05-12 09:20:42
【问题描述】:
在尝试为另一个问题构建 MCVE 时,我创建了一个 example 目录,其中包含一个文件,setup.py 包含以下内容:
from setuptools import setup
setup(
name='example',
)
并安装它
python3.6 setup.py sdist
python3.6 -m pip install --user dist/example-0.0.0.tar.gz
没有实际的包或模块,但某些东西已安装:
redacted:~/example> python3.6 -m pip list | grep example
DEPRECATION: The default format will switch to columns in the future. You can use --format=(legacy|columns) (or define a format=(legacy|columns) in your pip.conf under the [list] section) to disable this warning.
example (0.0.0)
现在我无法卸载它:
redacted:~/example> python3.6 -m pip uninstall example
Can't uninstall 'example'. No files were found to uninstall.
Other posts 建议可能有一个.pth 文件我必须从我的site-packages 目录中删除,但我没有看到:
redacted:~/example> find ~/.local/lib/python3.6/site-packages/ -name '*.pth'
redacted:~/example>
我刚刚对我的系统做了什么,我该如何撤消它?
【问题讨论】: