[Piuparts-devel] Bug#588313: moreinfo, please

Andreas Beckmann debian at abeckmann.de
Mon Nov 15 10:11:40 UTC 2010


On 2010-11-11 01:29, Holger Levsen wrote:
> tags 588313 + moreinfo
> thanks
> 
> Hi Andreas,
> 
> thanks for your bugreport, can you point me to a package where this is 
> actually a problem? http://piuparts.debian.org has logfiles for almost 90k 
> binary packages and I don't remember seeing this :-)

Well, it's not a state change tested by piuparts, so you don't see any
errors or similar things (unless dpkg throws some).

Just imagine a package foobar which does the following in its preinst:

   dpkg-divert --add --rename --divert-to /usr/bin/foo /usr/bin/bar

but does not clean this up in postrm. Or does clean it up incorrectly:

   dpkg-divert --remove --rename --divert-to /usr/bin/fuu /usr/bin/bar

If there was no /usr/bin/bar in the test environment, after purge no
(file) changes are left in the system - besides an entry in the
diversion database (IIRC, this file is ignored by piuparts because the
order of the entries might change). This system configuration change is
not detected by piuparts.

I needed this test for fixing all the diversion handling in the
nvidia-graphics-drivers* packages which was very messy. I used
snapshot.d.o to test upgrading from all old packages releases back to
some time even before lenny - every package left some (other) diversions
on the system that needed proper cleanup now for squeeze. piuparts did
not detect this until I introduced my hooks.

Another possible case: package bbb removes/takes over a diversion owned
by package aaa, the diversion will be gone after install-and-purge bbb
without a change detected by piuparts. (Unless a file change involving
the diverted file is detected - but if no package has this file, nothing
will be noticed.)


Andreas





More information about the Piuparts-devel mailing list