On 27Nov2017 20:20, Martin Schöön <martin.sch...@gmail.com> wrote:
Den 2017-11-26 skrev Cameron Simpson <c...@cskk.id.au>:
On 26Nov2017 10:00, nospam.Martin Schöön <martin.sch...@gmail.com> wrote:
Hmm, I seem to remember not being able to install packages with pip unless I
did sudo pip.

And this is exactly what I'm warning about. Many Linux users see some kind of
failure and just stick sudo on the front of the command. It is almost always
the wrong things to do, leading to effects in the OS install area instead of
being safely contained within one's home directory or work area.

Instead of reaching straight for sudo, look at pip's manual or help. You will
find that:

  pip install --user ...

installs modules local to your home directory, avoiding troublesome installs
into the OS area.

Guilty as charged.

So, how do I restore order in my Python 2.7 installation? Uninstall
everything that looks, smells and tastes like Python 2.7 and then
re-install?

Depeneds on your OS/distro. Redhat's RPM used to have some kind of --verify option to compare package definitions aginst what was physically present.

But if the package is mainstream you're probably ok? You could just live with it and do no more damage.

Otherwise, look to see what python packages are installed which you think you may have pipped, and reinstall those. But also, pip tends not to install things that are already present, so you might be fine.

Cheers,
Cameron Simpson <c...@cskk.id.au> (formerly c...@zip.com.au)
--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to