Hi!

On Sun, 2009-08-09 at 15:35:43 +0200, Guillem Jover wrote:
> On Fri, 2009-07-17 at 11:35:39 +0200, Michael Vogt wrote:
> > Package: dpkg
> > Version: 1.15.3.1
> 
> > I debugged a failure in ubuntu today where the package "update-motd"
> > was updated to a new version that contained no files (that was
> > intentional, the package was supposed to go away) [1].
> 
> > [1] https://bugs.launchpad.net/ubuntu/+source/update-motd/+bug/400462
> 
> > Dpkg noticed that the package was empty and purged it during (after?)
> > apt ran it with --unpack. Later apt tried to configure the package
> > (because in its worldview the package was a upgrade so it needs a
> > --unpack and then a --configure). This failed because the package was
> > no longer there. 
> 
> Reading DpkgTerminalLog it seems update-notifier-common “replaced”
> update-motd, thus dpkg disappeared it. The specific reason is that
> update-motd was not completely empty, and still contained empty
> directories that were also shipped by update-notifier-common, and dpkg
> considers this an implicit Replaces.
> 
> Dpkg will not make a package disappear when upgrading to a version
> that is (completely) empty.
> 
> > I would like to ask for a new force option that apt can use to turn
> > this into a non-fatal error. Either a --force-no-purge-if-empty (or
> > something similar) or a more broader --force-configure-bad (or a
> > better matching name). I implemented the later and will attach it to
> > this bugreport. But I'm also happy to do the former or solve it in a
> > different way. The patch is against the current ubuntu version of
> > dpkg, but it applies to current git.
> 
> I'd prefer to see apt not use even more ‘--force’ options (actually I'd
> rather see apt not use any at all! :). The problem here seems to be
> that apt does not have enough information to know that the package
> disappeared in that dpkg run. But this should have been notified
> through the status-fd channel (from modstatdb_note). OTOH I'm not sure
> how apt parses those state changes. And it might be more useful to add
> a: “log_action("disappear", otherpkg->name);” in process_archive()
> after the «(Noting disappearance of ...» printf. What do you think?

Ok, so because this change seems worthwhile in itself, and seems like
an elegant solution to your problem, I'm going to commit and close this
bug with it. If it's not enough or you need more stuff please open a
new bug report.

thanks,
guillem




-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to