pypa / pip

The Python package installer
https://pip.pypa.io/
MIT License
9.49k stars 3.01k forks source link

pip uninstall refuses to uninstall packags from ~/.local/lib/ #5176

Open mgedmin opened 6 years ago

mgedmin commented 6 years ago

Description:

I was trying to uninstall a package from my ~/.local/lib/python/site-packages and pip wouldn't let me:

What I've run:

$ pip uninstall tornado
Not uninstalling tornado at /home/mg/.local/lib/python2.7/site-packages, outside environment /home/mg/.venv

(/home/mg/.venv is a virtualenv created with --system-site-packages. ~/.venv/bin is in my $PATH.)

Note that pip from the virtualenv can install things into ~/.local/lib/ if I run pip install --user, it's just pip uninstall that seems to cause confusion.

(FWIW my first inclination was to run pip uninstall --user tornado, but pip uninstall doesn't accept --user.)

piotr-dobrogost commented 6 years ago

Raised in the past in issue #3352 Generally the implementation of schemes (and user scheme more than others) in pip is broken since the beginning; see issue #4575.

pradyunsg commented 6 years ago

I'm gonna let this stay open and resolve this as a part of #4575.