[Python-modules-team] Bug#916225: python3-docutils doesn't install on Sid armel/armhf/mips/mipsel

You-Sheng Yang vicamo at gmail.com
Tue Dec 11 16:45:34 GMT 2018

Package: python3-docutils
Version: 0.14+dfsg-3
Severity: grave
Justification: renders package unusable

Dear Maintainer,

While trying to install build-deps for linux kernel package,
python3-docutils failed to install on Sid armel/armhf/mips/mipsel and
passed on other official Sid architectures. The postinst script failed
with following error messages:

    Setting up python3-docutils (0.14+dfsg-3) ...
    update-alternatives: priority must be an integer
    Use 'update-alternatives --help' for program usage information.
    dpkg: error processing package python3-docutils (--configure):
     installed python3-docutils package post-installation script
     subprocess returned error exit status 2

With some more inspection into the postinst script, the for-loop inside
is to be blamed:

    for exe in /usr/share/docutils/scripts/python3/*
        update-alternatives --install /usr/bin/${exe##*/} ${exe##*/}
        $exe 20

Somehow dash failed to expand /usr/share/docutils/scripts/python3/*, so
that exec variable is simply '/usr/share/docutils/scripts/python3/*',
which is later expanded as extra dozens of update-alternatives'   
arguments. To be more detailed, at the time executed, dash path   
expansion still worked as it's able to expand /usr/share/* and
/usr/share/docutils*, but it failed to expand /usr/share/docutils/* and
any other pattern with a /usr/share/docutils/ prefix. Files has been
installed correctly and accessible, but dash simply unable to expand
such globs.

Replace that path glob with a `find ... -type f` fixes the problem.

-- System Information:
Debian Release: buster/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.18.0-2-amd64 (SMP w/8 CPU cores)
Locale: LANG=zh_TW.UTF-8, LC_CTYPE=zh_TW.UTF-8 (charmap=UTF-8), LANGUAGE=en_US:zh_TW (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages python3-docutils depends on:
ii  docutils-common  0.14+dfsg-3
ii  python3          3.7.1-2
ii  python3-roman    2.0.0-3

Versions of packages python3-docutils recommends:
ii  libpaper-utils    1.1.24+nmu5
ii  python3-pil       5.3.0-1
ii  python3-pygments  2.2.0+dfsg-2

Versions of packages python3-docutils suggests:
pn  docutils-doc               <none>
ii  fonts-linuxlibertine       5.3.0-4
pn  texlive-lang-french        <none>
ii  texlive-latex-base         2018.20181116-1
pn  texlive-latex-recommended  <none>

-- no debconf information

More information about the Python-modules-team mailing list