[Piuparts-devel] Bug#440310: Bug#440310: left files not reported correctly with --warn-on-others
John Wright
jsw at debian.org
Fri Aug 31 17:57:34 UTC 2007
On Fri, Aug 31, 2007 at 02:32:33PM +0200, Lucas Nussbaum wrote:
> Package: piuparts
> Version: 0.25
> Severity: important
>
> Hi,
>
> With --warn-on-others, left files are not reported correctly.
>
> Fact:
> I ran piuparts over 7000+ packages, and none of them failed because
> of left files. (but I got lots of "INFO:" lines about them)
>
> Analysis (after discussing this with ana):
> piuparts checks for left over files after purge. This means that
> /var/lib/dpkg/info/packagename.list is not available anymore.
> So all files from removed packages will be reported as 'not owned'. And
> you can't compare that with the package names from the command line
> anymore.
Well, the file ownership information is actually taken before the
package purge, and then files left after the purge are compared against
that information. Unfortunately, this can't associate files that dpkg
doesn't know about with a particular package, and therefore the option
ignores many left files (since it can't tell whether a file belongs to a
package specified on the command-line or another package).
So I agree, the option as it stands is kind of worthless, unless for
some strange reason the package leaves behind files that dpkg
actually knows about. Ideally, we would install the dependencies first,
take a file inventory, then install the specified packages. Then, after
purging, if --warn-on-others is specified, we could ignore any left
files that are in the dependencies inventory, and fail on any other left
files.
I'll start thinking about how to do this. Meanwhile, it seems
reasonable to either disable the option or print a big fat warning
indicating that it won't fail packages that leave behind files outside
of dpkg's knowledge.
--
John Wright
More information about the Piuparts-devel
mailing list