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

Re: Bug#887629: libc6: bad upgrade path: libexpat1 unpacked and python3 called before libc6 unpacked



Hi!

On Thu, 2018-01-18 at 21:45:51 +0100, Aurelien Jarno wrote:
> On 2018-01-18 20:38, Julian Andres Klode wrote:
> > On Thu, Jan 18, 2018 at 06:41:52PM +0100, Aurelien Jarno wrote:
> > > This failure is normal given libexpat1 requires the new libc which has
> > > not been unpacked yet.
> > 
> > Yeah, well, it needs to Pre-Depend on it then I guess, if it's being used
> > in preinst actions. The thing is that Depends only after postinst ordering,
> > not unpack ordering.
> 
> Well it's not the preinst script, but the prerm script. The problem is
> unpacking libexpat1 before libc6 breaks libexpat1 and not usable
> anymore.

Depends only applies at configure time, not unpack time anyway. In
addition in this case dpkg does not even know there's such dependency
because the new package does not depend on python any longer (and dpkg
only tests the dependencies of the new version not the old one).

> From what I understand from the debian-policy, a prerm script might
> consider that all the dependencies have been at least unpacked when
> called:
> 
> | "The package whose prerm is being called will be at least
> | “Half-Installed”. All package dependencies will at least be
> | “Half-Installed” and will have previously been configured and not
> | removed. If there was no error, all dependencies will at least be
> | “Unpacked”, but these actions may be called in various error
> | states where dependencies are only “Half-Installed” due to a
> | partial upgrade.

First, notice that half-installed is one state lower than unpacked. In
addition when it says that "All package dependencies will at least be
“Half-Installed” and will have previously been configured and not
removed.", this means that they will have been fully configured before
on any version, but not the depended-on version (if there's such
dependency now).

Thanks,
Guillem


Reply to: