How do I manually uninstall setuptools (installed by egg)?

David Cournapeau cournape at gmail.com
Fri Dec 12 11:25:14 CET 2008


On Thu, Dec 11, 2008 at 10:30 PM, Nick Craig-Wood <nick at craig-wood.com> wrote:
> David Cournapeau <cournape at gmail.com> wrote:
>>  On Wed, Dec 10, 2008 at 12:04 PM, Chris Rebert <clp at rebertia.com> wrote:
>> > On Tue, Dec 9, 2008 at 6:49 PM,  <excord80 at gmail.com> wrote:
>> >> On Ubuntu, I accidentally manually installed setuptools
>> >> http://pypi.python.org/pypi/setuptools/0.6c9 (by running the .egg file
>> >> as a shell script via sudo), and now realize I should just be using
>> >> apt to take care of my system Python packages.
>> >
>> > Really, why? setuptools has more Python packages/programs available
>> > and updates faster than Debian.
>> > It's also likely that some of the Debian Python packages are installed
>> > using setuptools anyway.
>> > So, why do you think apt and not setuptools is The Right Way(tm)?
>>
>>  Setuptools is certainly not the right way to install packages
>>  system-wide on debian, it is very likely to break the whole thing.
>
> It wouldn't be too difficult to make a .deb target which would collect
> all the files that did get installed into a package.  It would be a
> rather rough and ready package but would do the job.

Depends what you mean by would do the job: rather rough certainly does
not mean "would do the job" for something as essential as a package
IMO.

>
> The .deb would then be uninstallable in the usual (dpkg --purge) way.
>
> Did anyone think about that?

Yes, there is stddeb which does that (make a .deb package from a
setuptools package).


>
> easy_install can do that I think...

Not without a lot of hoola, unfortunately; for example, it breaks
stow, so I have to use specialy scripts to circumvent the damn thing
and make it what I tell him to do. I never understood what's easy
about easy install: it is broken in so many ways, and has caused me so
many pains - even when I was not using - that I do not trust it at
all. I only use it to download packages (and even then it manage to
fail more than work), and always install them from setup.py afterwards
(at which step I of course also have to circumvent setuptools if the
package uses setuptools).

cheers,

David



More information about the Python-list mailing list