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

Bug#926311: soundscaperenderer-nox: leaves alternatives after upgrade and purge: /usr/bin/ssr-*



Package: soundscaperenderer-nox
Version: 0.5.0~dfsg-3
Severity: important
User: debian-qa@lists.debian.org
Usertags: piuparts

Hi,

during a test with piuparts I noticed your package left unowned files on
the system after purge, which is a violation of policy 6.8:

https://www.debian.org/doc/debian-policy/ch-maintainerscripts.html#details-of-removal-and-or-configuration-purging

The leftover files are actually alternatives that were installed by the
package but have not been properly removed.

While there is ongoing discussion how to remove alternatives correctly
(see https://bugs.debian.org/71621 for details) the following strategy
should work for regular cases:
* 'postinst configure' always installs the alternative
* 'prerm remove' removes the alternative
* 'postrm remove' and 'postrm disappear' remove the alternative
In all other cases a maintainer script is invoked (e.g. upgrade,
deconfigure) the alternatives are not modified to preserve user
configuration.
Removing the alternative in 'prerm remove' avoids having a dangling link
once the actual file gets removed, but 'prerm remove' is not called in
all cases (e.g. unpacked but not configured packages or disappearing
packages) so the postrm must remove the alternative again
(update-alternatives gracefully handles removal of non-existing
alternatives).

Note that the arguments for adding and removing alternatives differ, for
removal it's 'update-alternatives --remove <name> <path>'.

Filing this as important as having a piuparts clean archive is a release
goal since lenny.

This was observed after an upgrade from stretch to buster.
Obsolete alternatives should be cleaned up in the postinst.

>From the attached log (scroll to the bottom...):

0m45.5s INFO: Warning: Package purging left files on system:
  /etc/alternatives/ssr-aap -> /usr/bin/ssr-aap.nox	 not owned
  /etc/alternatives/ssr-aap.1.gz -> /usr/share/man/man1/ssr-aap.nox.1.gz	 not owned
  /etc/alternatives/ssr-binaural -> /usr/bin/ssr-binaural.nox	 not owned
  /etc/alternatives/ssr-binaural.1.gz -> /usr/share/man/man1/ssr-binaural.nox.1.gz	 not owned
  /etc/alternatives/ssr-brs -> /usr/bin/ssr-brs.nox	 not owned
  /etc/alternatives/ssr-brs.1.gz -> /usr/share/man/man1/ssr-brs.nox.1.gz	 not owned
  /etc/alternatives/ssr-generic -> /usr/bin/ssr-generic.nox	 not owned
  /etc/alternatives/ssr-generic.1.gz -> /usr/share/man/man1/ssr-generic.nox.1.gz	 not owned
  /etc/alternatives/ssr-vbap -> /usr/bin/ssr-vbap.nox	 not owned
  /etc/alternatives/ssr-vbap.1.gz -> /usr/share/man/man1/ssr-vbap.nox.1.gz	 not owned
  /etc/alternatives/ssr-wfs -> /usr/bin/ssr-wfs.nox	 not owned
  /etc/alternatives/ssr-wfs.1.gz -> /usr/share/man/man1/ssr-wfs.nox.1.gz	 not owned
  /usr/bin/ssr-aap -> /etc/alternatives/ssr-aap	 not owned
  /usr/bin/ssr-binaural -> /etc/alternatives/ssr-binaural	 not owned
  /usr/bin/ssr-brs -> /etc/alternatives/ssr-brs	 not owned
  /usr/bin/ssr-generic -> /etc/alternatives/ssr-generic	 not owned
  /usr/bin/ssr-vbap -> /etc/alternatives/ssr-vbap	 not owned
  /usr/bin/ssr-wfs -> /etc/alternatives/ssr-wfs	 not owned
  /usr/share/man/man1/ssr-aap.1.gz -> /etc/alternatives/ssr-aap.1.gz	 not owned
  /usr/share/man/man1/ssr-binaural.1.gz -> /etc/alternatives/ssr-binaural.1.gz	 not owned
  /usr/share/man/man1/ssr-brs.1.gz -> /etc/alternatives/ssr-brs.1.gz	 not owned
  /usr/share/man/man1/ssr-generic.1.gz -> /etc/alternatives/ssr-generic.1.gz	 not owned
  /usr/share/man/man1/ssr-vbap.1.gz -> /etc/alternatives/ssr-vbap.1.gz	 not owned
  /usr/share/man/man1/ssr-wfs.1.gz -> /etc/alternatives/ssr-wfs.1.gz	 not owned


cheers,

Andreas

Attachment: soundscaperenderer-nox_0.5.0~dfsg-3.log.gz
Description: application/gzip


Reply to: