[Piuparts-devel] Bug#1086513: piuparts: wrong check (ERROR:) on missing files after dpkg-divert --no-rename
Lorenzo Puliti
plorenzo at disroot.org
Thu Oct 31 16:44:58 GMT 2024
Package: piuparts
Version: 1.4.4
Severity: normal
X-Debbugs-Cc: plorenzo at disroot.org
Dear piuparts maintainer,
I'm going to use dpkg-divert on essential files with one of my
package (runit-init); since files to be diverted are shipped by an
essential package, I'm using '--no-rename' option.
When the package is tested, piuparts ERROR with
0m11.9s INFO: Installation of ['./tmp/runit-init_2.1.2-61+salsaci+20241031+377_amd64.deb'] ok
0m11.9s DEBUG: Removing /tmp/tmpwm0glw6e/./tmp/runit-init_2.1.2-61+salsaci+20241031+377_amd64.deb
0m11.9s INFO: Running scripts post_install
0m11.9s DEBUG: Starting command: ['chroot', '/tmp/tmpwm0glw6e', 'eatmydata', 'tmp/scripts/post_install_exceptions']
0m11.9s DEBUG: Command ok: ['chroot', '/tmp/tmpwm0glw6e', 'eatmydata', 'tmp/scripts/post_install_exceptions']
0m11.9s DEBUG: Starting command: ['chroot', '/tmp/tmpwm0glw6e', 'eatmydata', 'tmp/scripts/post_install_remove_configs']
0m11.9s DUMP:
Not removing dir /etc/./apt
Not removing dir /etc/./apt/sources.list.d
removed '/etc/./apt/sources.list.d/local-apt-repository.list'
Not removing dir /etc/./apt/preferences.d
0m11.9s DEBUG: Command ok: ['chroot', '/tmp/tmpwm0glw6e', 'eatmydata', 'tmp/scripts/post_install_remove_configs']
0m11.9s DEBUG: Starting command: ['lsof', '-w', '+D', '/tmp/tmpwm0glw6e']
0m13.1s DEBUG: Command failed (status=1), but ignoring error: ['lsof', '-w', '+D', '/tmp/tmpwm0glw6e']
0m13.5s ERROR: WARN: Broken symlinks:
/etc/runit/stopit -> /run/runit.stopit (runit)
/etc/runit/reboot -> /run/runit.reboot (runit)
0m13.7s DEBUG: Starting command: ['debsums', '--root', '/tmp/tmpwm0glw6e', '-ac', '--ignore-obsolete']
0m14.2s DUMP:
debsums: missing file /tmp/tmpwm0glw6e/usr/sbin/invoke-rc.d.real (from init-system-helpers package)
debsums: missing file /tmp/tmpwm0glw6e/usr/sbin/service.real (from init-system-helpers package)
debsums: missing file /tmp/tmpwm0glw6e/usr/share/man/man8/invoke-rc.d.8.gz.real (from init-system-helpers package)
debsums: missing file /tmp/tmpwm0glw6e/usr/share/man/man8/service.8.gz.real (from init-system-helpers package)
0m14.2s DEBUG: Command failed (status=2), but ignoring error: ['debsums', '--root', '/tmp/tmpwm0glw6e', '-ac', '--ignore-obsolete']
0m14.2s ERROR: FAIL: debsums reports modifications inside the chroot:
debsums: missing file /usr/sbin/invoke-rc.d.real (from init-system-helpers package)
debsums: missing file /usr/sbin/service.real (from init-system-helpers package)
debsums: missing file /usr/share/man/man8/invoke-rc.d.8.gz.real (from init-system-helpers package)
debsums: missing file /usr/share/man/man8/service.8.gz.real (from init-system-helpers package)
after runit-init (the package that adds the diversion) is removed, piuparts detects that,
for example, /usr/sbin/invoke-rc.d.real should be there (but it's missing) when
in fact is /usr/sbin/invoke-rc.d that should be there (and it's not missing).
I believe my package does it the right way, when it's removed it removes the diversion and it
makes sure that diverted files are restored in their original location.
At package removal the diversion is removed so I'm not sure why piuparts detects that
files should be still at the diverted location.
Full piuparts test is at salsa
https://salsa.debian.org/debian/runit/-/jobs/6512551
code that adds and removes the diversion can be found at salsa
https://salsa.debian.org/debian/runit/-/blob/next/debian/runit-init.preinst?ref_type=heads
https://salsa.debian.org/debian/runit/-/blob/next/debian/runit-init.prerm?ref_type=heads
https://salsa.debian.org/debian/runit/-/blob/next/debian/runit-init.postrm?ref_type=heads
Thanks,
Lorenzo
-- System Information:
Debian Release: trixie/sid
APT prefers unstable
APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 6.8.12-amd64 (SMP w/4 CPU threads; PREEMPT)
Kernel taint flags: TAINT_FIRMWARE_WORKAROUND, TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US:en
Shell: /bin/sh linked to /usr/bin/dash
Init: runit (via /run/runit.stopit)
LSM: AppArmor: enabled
Versions of packages piuparts depends on:
ii debsums 3.0.2.1
ii libjs-sphinxdoc 7.4.7-3
ii lsb-release 12.1-1
ii lsof 4.95.0-1.1
ii mount 2.40.2-9
ii piuparts-common 1.4.4
ii python3 3.12.6-1
ii python3-debian 0.1.49
Versions of packages piuparts recommends:
ii adequate 0.16.19
ii debootstrap 1.0.137
Versions of packages piuparts suggests:
ii docker.io 26.1.5+dfsg1-2+b1
ii schroot 1.6.13-5
-- no debconf information
More information about the Piuparts-devel
mailing list