Processed: Re: Bug#1057675: urlview: postinst uses /usr/share/doc content (Policy 12.3): /usr/share/doc/urlview/examples/sample.urlview

2023-12-06 Thread Debian Bug Tracking System
Processing control commands:

> tags -1 + pending
Bug #1057675 [urlview] urlview: postinst uses /usr/share/doc content (Policy 
12.3): /usr/share/doc/urlview/examples/sample.urlview
Added tag(s) pending.

-- 
1057675: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1057675
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems



Bug#1057675: urlview: postinst uses /usr/share/doc content (Policy 12.3): /usr/share/doc/urlview/examples/sample.urlview

2023-12-06 Thread наб
Control: tags -1 + pending

On Thu, Dec 07, 2023 at 02:28:39AM +0100, Andreas Beckmann wrote:
> Package: urlview
> Version: 1b-1
> 
> a test with piuparts revealed that your package uses files from
> /usr/share/doc in its maintainer scripts which is a violation of
> Policy 12.3: "Packages must not require the existence of any files in
> /usr/share/doc/ in order to function."
> https://www.debian.org/doc/debian-policy/ch-docs.html#additional-documentation
> 
> These files must be moved to /usr/share/$PACKAGE and may be symlinked
> from /usr/share/doc/$PACKAGE.
Comparing 0.9-24 and 1b-1, I see that I started to use ucf with a
  /usr/share/urlview/examples/sample.urlview /etc/urlview/system.urlview
stanza. I'm gonna be frank: I don't know why, since this file is already
covered by the conffile mechanism. And, re-reading the conffile sexion,
  https://www.debian.org/doc/debian-policy/ap-pkg-conffiles.html
> Note that a package should not modify a dpkg-handled conffile in its
> maintainer scripts. Doing this will lead to dpkg giving the user
> confusing and possibly dangerous options for conffile update when the
> package is upgraded.
which is precisely what ucf does.

Thankfully, we're in a fortunate situation of there having only been one
urlview with ucf, and /e/u/s.u is installed (and conffile-tagged)
in both versions, so an upgrade-test shows we can drop it
with the normal conffile mechanism correctly handling the situation.

Fixed in
  
https://git.sr.ht/~nabijaczleweli/urlview.deb/commit/13cd0e45d02da500ff0b8ed32701bd9ac9131454

Thank you for your report!
This would be a lot uglier if we ended up with multiple versions
with double conffile+ucf handling, I think.

Best,
наб


signature.asc
Description: PGP signature


Bug#1057675: urlview: postinst uses /usr/share/doc content (Policy 12.3): /usr/share/doc/urlview/examples/sample.urlview

2023-12-06 Thread Andreas Beckmann
Package: urlview
Version: 1b-1
Severity: serious
User: debian...@lists.debian.org
Usertags: piuparts

Hi,

a test with piuparts revealed that your package uses files from
/usr/share/doc in its maintainer scripts which is a violation of
Policy 12.3: "Packages must not require the existence of any files in
/usr/share/doc/ in order to function."
https://www.debian.org/doc/debian-policy/ch-docs.html#additional-documentation

These files must be moved to /usr/share/$PACKAGE and may be symlinked
from /usr/share/doc/$PACKAGE.

This piuparts test prevents the installation of (most) files into
/usr/share/doc with 'dpkg --path-exclude=...'.

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

  Setting up urlview (1b-1) ...
  Error: The new file /usr/share/doc/urlview/examples/sample.urlview does not 
exist!
  dpkg: error processing package urlview (--configure):
   installed urlview package post-installation script subprocess returned error 
exit status 1
  Processing triggers for libc-bin (2.37-12) ...
  Errors were encountered while processing:
   urlview


Cheers,

Andreas


urlview_1b-1.log.gz
Description: application/gzip