[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

purge does not remove triggers?



Hello,

in short: removing a package that has requested File triggers, does not remove those triggers from /var/lib/dpkg/triggers/File. Is this intended behaviour?

In long: installing the 'menu' package (tested on Debian 5 and Ubuntu 10.04) causes three triggers to end up in /var/lib/dpkg/triggers/File:
$ grep menu /var/lib/dpkg/triggers/File
/usr/share/menu menu
/usr/lib/menu menu
/etc/menu-methods menu

However, removing+purging menu does not remove those triggers. Is this intended behaviour? I'm asking because in a situation with a non-Debian package, I installed a version without trigger support after having used a package that did have trigger support. The trigger still being present in /var/lib/dpkg/triggers/File therefore caused errors in configuring said package.

I have been unable to find any conclusive information on whether leaving triggers in that file is intended behaviour. I did find these snippets in /usr/share/doc/dpkg-dev/triggers.txt.gz but I am not sure in how far they describe the behaviour I am seeing as good or bad.

"""These interest files are not updated to remove a package just because
a state change causes it not to be interested in any triggers any more
- they are updated when we remove or unpack."""

and

"""When a package is unpacked or removed, its triggers control file will
be parsed and /var/lib/dpkg/triggers/* updated accordingly."""

I'm looking forward to, in short, a yes or no answer, and in long, explanation of these two snippets. Thank you for your time.

Kind regards,
Peter van Dijk

Reply to: