Ubuntu QA:
BlogBrainstormPackage status
Log in
Ubuntu QA
The Ubuntu community has contributed 15328 ideas, 75068 comments, 1387413 votes

Idea #3753: Remove orphaned apps via Synaptic



up
403
down
Written by rsgill the 7 Mar 08 at 16:44. Category: System.
Related to: Nothing/Others. Status: New
Description
Right now when an application is installed in Synaptic, all the dependencies of the application are automatically installed. However, when the same application is uninstalled, only the application itself is uninstalled by Synaptic; all the dependencies of the application that were automatically installed by Synaptic are left intact.

The only way to remove the automatically installed dependencies is to run sudo apt-get autoremove from the command line.

Synaptic should provide an option to remove the automatically installed dependencies that were installed with an application when that application is being uninstalled using Synaptic.

Having a user drop to the command line to achieve this is not acceptable especially for new users.
Tags: (none)

Attachments
bug Bug #113247 : Synaptic should warn about auto-removable packages


Duplicates


Comments
endeavor wrote on the 7 Mar 08 at 17:24
Doesn't the Installed (auto removable) status list all of those packages already?

jmmL wrote on the 7 Mar 08 at 17:46
@ endeavor
not in my experience - unless i'm missing something.

laervian wrote on the 7 Mar 08 at 18:27
Actually I can confirm what endeavor wrote. Just go into synaptic -> status -> Installed (autoremovable). It lists packages which would be removed by sudo apt-get autoremove from the command line.

Now, that maybe synaptic needs better organization is true; I did not realize it had this feature for many months.

mateusza wrote on the 7 Mar 08 at 20:54
deborphan

flip314 wrote on the 7 Mar 08 at 21:44
I submitted this as a bug some time ago. Here's the reference:
https://bugs.launchpad.net/ubuntu/+source/synaptic/+bug/113247

flip314 wrote on the 7 Mar 08 at 21:45
Hey neat! I can attach the bug directly to the idea. That's a good idea in itself.

antistress wrote on the 8 Mar 08 at 04:00
it already exists with synaptic since Ubuntu 6.10
There is a filter to display packages that can be automatically deleted

wombatworld wrote on the 8 Mar 08 at 04:20
Take a look at the way aptitude handles this. It distinguishes packages intentionally installed from those that were just installed to meet a dependency. When the last package that depends on a particular package is removed (or stops depending on it), that package is automatically marked for deletion. So it purges cruft as it goes along; it would be good if Synaptic did this.

If Synaptic is enhanced to do this, it would be good if it could share the data with aptitude, so users could switch back an forth without losing the info about which packages were explicitly selected.

ubunteando wrote on the 8 Mar 08 at 10:16
Totally agree...

I also hate to have to hidden folders of the programs I have deleted still there... Agaist my will! There should be an easy, efficient and unified way to do all the install/uninstall tasks.

choad wrote on the 8 Mar 08 at 13:42
i'd actually vote that you leave it, but have it so that you can run up a disk clean-up utility (one that you are prompted to use when low on space) which will remove these packages, among other un needed files (possibly giving you a list of never used applications?) to re-gain some space.

rasta_freak wrote on the 8 Mar 08 at 14:03
apt, dselect, aptitude, synaptic and friends support this for years. In synaptic it's just a few clicks away, and this feature is fully documented. No need to change synaptic, just propagate this feature in Ubuntu docs, and problem solved.

flip314 wrote on the 9 Mar 08 at 07:49
apt-get tracks orphaned packages but doesn't remove them. the best way to keep aptitude and apt-get/synaptic synched is to never use aptitude.

sciurus wrote on the 11 Mar 08 at 16:51
Better to use aptitutde and never apt-get; debian considers apt deprecated.

flip314 wrote on the 12 Mar 08 at 19:36
apt-get now has all the functionality of aptitude. as long as you're using synaptic, it's better to use apt-get.

Also, I can't find any reference to support that Debian now considers apt-get deprecated. It does appear that it was at one time looked down upon before apt-get was given all the same features aptitude has anyway.

tgape wrote on the 1 May 08 at 22:54
Auto-removing all packages which were installed due to an obsolete dependence is not the same as what this idea is requesting. Furthermore, I've had systems break because of an operation uninstalling all such packages, because of one of those applications turning out to be critical. Note that this experience was with Gentoo, not Ubuntu, but the concept was basically the same. Also note that I haven't used Gentoo in years, they may have fixed things.

For example, a user installs a package that depends upon perl. Perl wasn't installed by default (Gentoo being a Python-based system), so perl was installed as a dependency. The user then developed a perl script that wrapped around that package and handled a few failings. Over the course of several months, more and more code goes into the wrapper, and it uses the package less and less. Finally, he eliminates his need for the package entirely. He then removes the package as it's no longer needed. Gentoo helpfully removes perl, too.

Now, the actual incident that really showed this issue off was worse, because the application uninstall process removed all registered modules it had when it was uninstalled, and the deliberately installed module was replaced with a home-grown module, so that uninstall process actually obliterated the replacement code, in addition to uninstalling the replacement code's dependency. Hopefully, none of the Ubuntu uninstall processes would do such uncontrolled actions - but the possibility is probably there, even if no current package does that, and even if there are process controls to try and catch such conceptually broken ideas.


Having the option to remove the orphaned packages from this specific package or these specific packages we're uninstalling right now would be, IMHO, a good thing. Having the orphaned packages removed for any package uninstall would not be.

I would need to do a long review of exactly what would be uninstalled to ever use an option to remove all orphaned packages.

brnetonboy wrote on the 9 Jul 08 at 23:22
This goes hand in hand with the idea about keeping a history of installed programs.

That solves the obvious problem of accidentally removing a dependency that was needed. But if you think about it there are only 2 cases where a dependency would be needed: 1. if it was already installed and being used beforehand, or 2. if some other program which was installed later needs it as a dependency.

If there is a history, then it can check to see which dependencies were already installed prior to the initial installation, and it can also check to see if programs installed afterwards need that particular dependency.

This is the way computers should always have been designed!


Post your comment