Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #189468

Re: Removing old python packages installed with pip

From David Wright <deblis@lionunicorn.co.uk>
Newsgroups linux.debian.user
Subject Re: Removing old python packages installed with pip
Date 2017-12-02 16:30 +0100
Message-ID <uShTQ-3aa-5@gated-at.bofh.it> (permalink)
References <uRUDU-5yP-13@gated-at.bofh.it> <uRVJD-6aJ-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri 01 Dec 2017 at 12:42:35 (-0300), Eike Lantzsch wrote:
> On Friday, December 1, 2017 3:24:47 PM -03 Urs Thuermann wrote:
> > On a machine running Debian stretch I have installed python3, which is
> > currently python3.5.  Nothing of python3.4 is present.
> > 
> > But in /usr/local/lib/python3.4/dist-packages/ a number of packages is
> > still installed.  Probably, these have been installed using pip3 when
> > python3.4 was current.
> > 
> > Now, it seems pip3 isn't able to remove packages from that old
> > directory.  Is it safe to just rm -r /usr/local/lib/python3.4?

You should preserve /usr/local/lib/python3.4/dist-packages/,
so removing just the files, and not *all* the directories, is safer.

> If those packages were installed together with the Debian system then 
> deinstall with aptitude or apt remove.

If Debian installs files (other than empty directories) under
/usr/local/, I would file a bug. That tree is for you, not Debian.

> If you mix two different package installers the consequence is that one does 
> not know about the other and they can interfere with each other.
> On Debian always install packages the "Debian way".
> Don't make a Frankendebian:
> https://wiki.debian.org/DontBreakDebian

My understanding of "Frankendebian" is a system that mixes *Debian*
versions. There have to be ways of adding other suites of software
to a Debian system and, if they're for general rather than personal
use, the /usr/local/ tree is a good way to go. Why else bother to
have /usr/local/bin in the default $PATH?

>From the reference above: "Installing software to the /usr/local will
make it available to all users, and will not interfere with the
package manager. The stow package can be useful for managing software
installed to /usr/local."

Cheers,
David.

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Removing old python packages installed with pip Urs Thuermann <urs@isnogud.escape.de> - 2017-12-01 15:40 +0100
  Re: Removing old python packages installed with pip Eike Lantzsch <zp6cge@gmx.net> - 2017-12-01 16:50 +0100
    Re: Removing old python packages installed with pip David Wright <deblis@lionunicorn.co.uk> - 2017-12-02 16:30 +0100
      Re: Removing old python packages installed with pip <tomas@tuxteam.de> - 2017-12-02 16:40 +0100
    Re: Removing old python packages installed with pip Urs Thuermann <urs@isnogud.escape.de> - 2017-12-06 22:40 +0100
  Re: Removing old python packages installed with pip deloptes <deloptes@gmail.com> - 2017-12-02 07:50 +0100
    Re: Removing old python packages installed with pip Urs Thuermann <urs@isnogud.escape.de> - 2017-12-06 22:50 +0100

csiph-web