Hello, On Mon, Jun 26, 2017 at 10:23:56PM +0200, Ralf Treinen wrote:
> we currently have in sid 84 maintainer scripts not using strict mode. > That is, they neither start on "#!/bin/[ba]sh -e", nor do a "set -e". Thanks to everybody for your feedback. I guess I will stick with severity=normal for the moment. The MBF template, list of offending maintainer scripts, and dd-list are attached. -Ralf.
Dear maintainer, at least one of the maintainer scripts (preinst, postinst, prerm, postrm) of the package #PACKAGE# does not use strict mode. Policy section 10.4 says: Shell scripts (sh and bash) [..] should almost certainly start with set -e so that errors are detected. Every script should use set -e or check the exit status of every command. Please insert a "set -e" at the beginning of your script to enable strict mode. You should not replace this by a first line "#!/bin/sh -e" as it is not effective when your script is executed by an explicit invocation of sh. Note that this might make your script fail in cases where it did not fail before. This is the purpose of strict mode - make it fail when any unexpected error is encountered. You should make sure that you catch any error (non-zero exit codes of commands) that you decide to tolerate. Techniques to locally catch an error include using appropriate options to your command when available, adding a " || true" at the end of the command, or selectively switching off strict mode by "set +e" and switching it back on again later by "set -e". This bug filing has been discussed and approved in thread [1]. -Ralf. [1] https://lists.debian.org/debian-devel/2017/06/msg00342.html
asterisk-prompt-de_2.0-1.1/preinst authbind_2.1.2/postinst authbind_2.1.2/prerm bcache-tools_1.0.8-2+b1/preinst bible-kjv_4.29+b1/postinst bible-kjv_4.29+b1/postrm bible-kjv_4.29+b1/prerm bible-kjv-text_4.29/postinst bible-kjv-text_4.29/prerm bind9_1:9.10.3.dfsg.P4-12.3/postrm binfmtc_0.17-2+b1/postinst binfmtc_0.17-2+b1/postrm bwbar_1.2.3-2.1+b2/prerm ca-certificates-mono_4.6.2.7+dfsg-1/postinst checksecurity_2.0.16+nmu1/preinst clips_6.24-3.2/postinst cxref_1.6e-2+b1/postrm debbugs_2.4.1.1/postrm debfoster_2.7-2.1+b1/postrm discover_2.1.2-7.1/postrm discover_2.1.2-7.1/preinst dsh_0.25.10-1.3/postinst dsh_0.25.10-1.3/postrm dsh_0.25.10-1.3/preinst dvifb_1:01.03-14.2/postinst dvifb_1:01.03-14.2/postrm geki3_1.0.3-8.1/postinst geki3_1.0.3-8.1/postrm gjiten_2.6-3/postinst gnukhata-core-engine_2.6.1-3/postrm golang-godebiancontrol-dev_0.0~git20140119-1/preinst guidedog_1.2.0-3+b1/postrm hyperspec_1.30+nmu2/postinst kterm_6.2.0-46.2/postinst kterm_6.2.0-46.2/prerm ldp-docbook-xsl_0.0.20040321-3/preinst ldp-docbook-xsl_0.0.20040321-3/prerm libclips_6.24-3.2/postinst libclips_6.24-3.2/prerm linpac_0.24-1+b1/postrm logtool_1.2.8-10/postrm logtool_1.2.8-10/preinst lpr_1:2008.05.17.2+b1/postinst lpr_1:2008.05.17.2+b1/postrm manpages-posix-dev_2013a-2/postinst manpages-posix-dev_2013a-2/postrm manpages-posix-dev_2013a-2/preinst mgetty-docs_1.1.36-3/preinst mgetty-fax_1.1.36-3+b1/preinst mgetty-voice_1.1.36-3+b1/postrm mime-support_3.60/prerm pmw-doc_1:4.29-1/postinst pmw-doc_1:4.29-1/preinst python-imaging-doc-html_1.1.2-1.2/postinst python-imaging-doc-pdf_1.1.2-1.2/postinst python-kde4_4:4.14.3-2/postinst remembrance-agent_2.12-7+b2/prerm samba_2:4.6.5+dfsg-2/prerm samba-common-bin_2:4.6.5+dfsg-2/prerm samhain_4.1.4-2/preinst sauce_0.9.0+nmu3/postrm scalable-cyrfonts-tex_4.17/postinst scalable-cyrfonts-tex_4.17/postrm scanlogd_2.2.5-3.3/postinst scanlogd_2.2.5-3.3/postrm scanlogd_2.2.5-3.3/prerm sendfile_2.1b.20080616-5.3+b3/preinst simba_0.8.4-4.3/postrm spacearyarya_1.0.2-7.1/postinst spacearyarya_1.0.2-7.1/postrm suricata_4.0.0-beta1-1~exp1/preinst swapspace_1.10-4+b2/postinst t1-cyrillic_4.17/postrm t1-oldslavic_4.17/postinst t1-oldslavic_4.17/postrm t1-teams_4.17/postinst t1-teams_4.17/postrm websimba_0.8.4-4.3/postinst websimba_0.8.4-4.3/postrm whizzytex_1.3.2-1.3/prerm wodim_9:1.1.11-3+b2/preinst
Adam Majer <ad...@zombino.com> lpr Andreas Barth <a...@ayous.org> mgetty Andreas Barth <a...@not.so.argh.org> debfoster (U) Andrew Bartlett <abartlet+deb...@catalyst.net.nz> samba (U) Anton Zinoviev <zinov...@debian.org> scalable-cyrfonts Antonio Cardoso Martins <digiplan...@gmail.com> guidedog Ardo van Rangelrooij <a...@debian.org> ldp-docbook-stylesheets (U) Arturo Borrero Gonzalez <art...@debian.org> suricata (U) Balasankar C <balasank...@autistici.org> gnukhata-core-engine Botond Botyanszki <b...@users.sourceforge.net> gjiten Camm Maguire <c...@debian.org> cxref Charles Plessy <ple...@debian.org> mime-support (U) Colin Tuckley <col...@debian.org> linpac (U) Colin Watson <cjwat...@debian.org> debbugs (U) David Mohr <da...@mcbf.net> bcache-tools David Nusinow <dnusi...@debian.org> discover (U) Debbugs developers <debian-debb...@lists.debian.org> debbugs debfoster Maintainer Team <pkg-debfos...@teams.debian.net> debfoster Debian Common Lisp Team <pkg-common-lisp-de...@lists.alioth.debian.org> hyperspec Debian Games Team <pkg-games-de...@lists.alioth.debian.org> geki3 spacearyarya Debian Hamradio Maintainers <debian-h...@lists.debian.org> linpac Debian Install System Team <debian-b...@lists.debian.org> discover Debian Mono Group <pkg-mono-gr...@lists.alioth.debian.org> mono Debian Qt/KDE Maintainers <debian-qt-...@lists.debian.org> pykde4 Debian Samba Maintainers <pkg-samba-ma...@lists.alioth.debian.org> samba Debian XML/SGML Group <debian-xml-sgml-p...@lists.alioth.debian.org> ldp-docbook-stylesheets Don Armstrong <d...@debian.org> debbugs (U) Eduard Bloch <bl...@debian.org> cdrkit (U) Eugene V. Lyubimkin <jackyf.de...@gmail.com> swapspace Florian Weimer <f...@deneb.enyo.de> debfoster (U) Francesco Paolo Lovergine <fran...@debian.org> manpages-posix Gaudenz Steinlin <gaud...@debian.org> discover (U) Gianfranco Costamagna <locutusofb...@debian.org> guidedog (U) Ian Jackson <i...@davenant.greenend.org.uk> sauce Ian Jackson <ijack...@chiark.greenend.org.uk> authbind ISHIKAWA Mutsumi <ishik...@debian.org> kterm Ivo De Decker <iv...@debian.org> samba (U) Javier Fernandez-Sanguino Pen~a <j...@computer.org> remem Javier Fernandez-Sanguino Pen~a <j...@debian.org> clips Javier Fernández-Sanguino Peña <j...@computer.org> checksecurity Javier Fernández-Sanguino Peña <j...@debian.org> samhain Jelmer Vernooij <jel...@debian.org> samba (U) Jo Shields <direct...@apebox.org> mono (U) Joerg Jaspert <jo...@debian.org> cdrkit Julien Danjou <a...@debian.org> bwbar Junichi Uekawa <dan...@debian.org> binfmtc dsh whizzytex LaMont Jones <lam...@debian.org> bind9 Laszlo Boszormenyi (GCS) <g...@debian.hu> mime-support (U) Ludovic Drolez <ldro...@debian.org> gjiten (U) Marc Haber <mh+debian-packa...@zugschlus.de> debfoster (U) Mario Joussen <jous...@debian.org> asterisk-prompt-de Martin Schulze <j...@debian.org> sendfile Mathieu Parent <sath...@debian.org> samba (U) Matthew Vernon <matt...@debian.org> bible-kjv Maximiliano Curia <m...@debian.org> pykde4 (U) Michael Gilbert <mgilb...@debian.org> bind9 (U) Michael Meskes <mes...@debian.org> pykde4 (U) Michael Stapelberg <stapelb...@debian.org> golang-godebiancontrol-dev Michael Vogt <m...@debian.org> scanlogd Mime-Support Maintainers <mime-supp...@plessy.org> mime-support Mirco Bauer <mee...@debian.org> mono (U) Modestas Vainius <mo...@debian.org> pykde4 (U) Otavio Salvador <ota...@debian.org> discover (U) Peter Van Eynde <pvane...@debian.org> hyperspec (U) Petter Reinholdtsen <p...@debian.org> discover (U) Pierre Chifflier <pol...@debian.org> suricata Pirate Praveen <prav...@debian.org> gnukhata-core-engine (U) Radu Spineanu <r...@debian.org> simba Robie Basak <robie.ba...@canonical.com> bind9 (U) Robie Basak <ro...@justgohome.co.uk> bcache-tools (U) Sam Hocevar (Debian packages) <sam+...@zoy.org> geki3 (U) spacearyarya (U) tmview Simon Richter <s...@debian.org> python-imaging-doc-handbook Steve Langasek <vor...@debian.org> samba (U) Steve McIntyre <93...@debian.org> cdrkit (U) Sune Vuorela <s...@debian.org> pykde4 (U) Wouter Verhelst <wou...@debian.org> logtool pmw