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

Re: Bug#1081022: ITP: libcurlfs -- mounts remote HTTP/HTTPS URLs as a FUSE filesystem



Am Tue, Oct 15, 2024 at 08:12:44PM +0200, schrieb наб:
> > > This configuration fresh-installs and upgrades fine for me on bookworm.
> > > I've updated the gits thus.
> > Looks fine to me too. Autoremove even picks up httpfs2 for removal. Neat. I
> > didn't know that handles transitional packages!
> >     $ apt-get autoremove
> >     Reading package lists... Done
> >     Building dependency tree... Done
> >     Reading state information... Done
> >     The following packages will be REMOVED:
> >       fuse httpfs2 libfuse2
> I remember reading some manual that said to format transitionals like this,
> for "special handling", didn't know that was this. Cool!

fwiw libapt code (so most front ends with the notable exception of
aptitude and external solvers as this is part of the internal solving
they skip) recognizes if a manual installed package changes to section
oldlibs in an upgrade and if so marks new packages this upgrade caused
to be manually installed (normally they would be auto-installed) while
setting the oldlibs package to auto-installed.

This is a one time action (at the moment the package changes section),
so if a user for some reason wants to keep the oldlibs package installed
all they have to do is mark it as manual installed (again).


Without this feature the oldlibs package would not have been offered for
autoremoval (as it would be still marked manual installed) and if the
user would ask for the removal of the old transitional package later
autoremoval would "helpfully" suggest the removal of the transitioned-to
package – easy to solve but probably not what the user meant.

The (re)move of the manual installation from the oldlibs package is
"new", I implemented that only 9 years ago (1.1~exp9), that oldlibs
new dependencies are marked manual is 14 years old (to prevent the
"helpful" suggestion mentioned earlier; not from me).


So, technically this isn't autoremove being clever, it is "just" some
code hidden deep in the internal solving that makes autoremove look
good later on – and one of the reasons why alternative solvers like
aspcud, solver3 or the one in aptitude have a hard time catching up.
Resolving Depends is (fsvo) easy, the fun starts with Recommends and
heuristics like this one.

(So, why not autoremove, you ask? It would need to invent a way for the
 user to declare that they want to keep the transitional package anyhow
 for example)

Bonus tip:
If you 'cheat' and test your upgrades with `dpkg -i` this and many other
things wont happen, so don't cheat, test them properly! If you don't
feel like setting up a repository you can skip that with e.g.
apt full-upgrade --with-source ./path/to/foo.changes


Best regards

David Kalnischkies

Attachment: signature.asc
Description: PGP signature


Reply to: