Install fuse3 instead of fuse during charm/livefs/snap builds
Current CPC image builds with livecd-rootfs fail with the following
error:
RUN: /usr/share/launchpad-buildd/bin/in-target buildlivefs \
--backend=lxd --series=jammy --arch=amd64 LIVEFSBUILD-320984 \
--project ubuntu-cpc --datestamp 20220110 --image-format ext4 \
--image-target aws
[snipped]
Get:38 http://ftpmaster.internal/ubuntu jammy/main amd64 \
libfuse2 amd64 2.9.9-5ubuntu2 [90.1 kB]
Get:39 http://ftpmaster.internal/ubuntu jammy/main amd64 \
fuse amd64 2.9.9-5ubuntu2 [27.4 kB]
[snipped]
[2022-01-10 11:57:46] lb_chroot_package-lists install
[snipped]
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
fuse3 : Breaks: fuse
E: Unable to correct problems, you have held broken packages.
This problem should be fixed when installing "fuse3" instead of
"fuse".
Refactor multiple implementations of operation command helpers
We had several nearly-identical implementations of `run_build_command`
and related testtools matchers floating around. Much of
launchpad-buildd is glue between other programs, so it makes sense for
it to have very careful checks on which subprocesses it runs, but it
doesn't need to have quite so much duplicated code in the process;
consolidate all these into common locations.
Refactor extra status handling to be common to all build types
Checking for the JSON status file on each status call is fairly cheap,
and it's convenient to have this in common code rather than having to
implement it separately for each build type that needs it. I also made
the operation-side code a little more general so that it's easy to add
arbitrary key-value pairs to the current status, which will be useful
shortly.