[R-pkg-team] Bug#942469: r-cran-rmarkdown: directory to symlink conversion not correctly handled on upgrade

Vincent Danjean vdanjean at debian.org
Wed Oct 16 22:57:28 BST 2019


Package: r-cran-rmarkdown
Version: 1.16+dfsg-1
Followup-For: Bug #942469

The reverse is also right (bad handling of symlink to directoy
conversion by dpkg) and affects r-cran-rmarkdown:

If I read correctly the sources, there was a symlink
/usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim -> ../../../../shiny/www/shared/bootstrap/shim
(commented out in debian/links)
And now /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim is a directory
and only usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim/html5shiv.min.js is a symlink

However, on upgrade, /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim
is not converted to directory and I suspect that the html5shiv.min.js
file in the r-cran-shiny package is overwriten by rmarkdown.
Test :
$ ls -ld /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim
lrwxrwxrwx 1 root root 43 janv. 16  2019 /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim -> ../../../../shiny/www/shared/bootstrap/shim
[ the old symlink is still here on my machine ]
$ sudo apt install --reinstall r-cran-shiny
[...]
$ ls -l /usr/lib/R/site-library/shiny/www/shared/bootstrap/shim
total 8
lrwxrwxrwx 1 root root   59 juil. 10 17:53 html5shiv.min.js -> ../../../../../../../nodejs/html5shiv/dist/html5shiv.min.js
-rw-r--r-- 1 root root 4433 juil. 10 17:53 respond.min.js
[ the html5shiv.min.js is wrong, this will be my next bug report ]
$ sudo apt install --reinstall r-cran-rmarkdown
[...]
$ ls -l /usr/lib/R/site-library/shiny/www/shared/bootstrap/shim
total 8
lrwxrwxrwx 1 root root 68 oct.   7 15:00 html5shiv.min.js -> ../../../../../../../../share/nodejs/html5shiv/dist/html5shiv.min.js
lrwxrwxrwx 1 root root 61 oct.   7 15:00 respond.min.js -> ../../../../../shiny/www/shared/bootstrap/shim/respond.min.js

 => both file from the r-cran-shiny package have been modified
 [ the first file have been "fixed", but the seconde one leads to a circular symlink... ]

Now, fixing locally the bug :
$ sudo rm /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim
$ sudo apt install --reinstall r-cran-shiny
$ ls -l /usr/lib/R/site-library/shiny/www/shared/bootstrap/shim
total 8
lrwxrwxrwx 1 root root   59 juil. 10 17:53 html5shiv.min.js -> ../../../../../../../nodejs/html5shiv/dist/html5shiv.min.js
-rw-r--r-- 1 root root 4433 juil. 10 17:53 respond.min.js
$ sudo apt install --reinstall r-cran-rmarkdown
[...]
$ ls -l /usr/lib/R/site-library/shiny/www/shared/bootstrap/shim
total 8
lrwxrwxrwx 1 root root   59 juil. 10 17:53 html5shiv.min.js -> ../../../../../../../nodejs/html5shiv/dist/html5shiv.min.js
-rw-r--r-- 1 root root 4433 juil. 10 17:53 respond.min.js
[ nothing changed, good ]
$ ls -ld /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim
drwxr-xr-x 2 root root 4096 oct.  16 23:51 /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim
$ ls -l /usr/lib/R/site-library/rmarkdown/rmd/h/bootstrap/shim
total 8
lrwxrwxrwx 1 root root 68 oct.   7 15:00 html5shiv.min.js -> ../../../../../../../../share/nodejs/html5shiv/dist/html5shiv.min.js
lrwxrwxrwx 1 root root 61 oct.   7 15:00 respond.min.js -> ../../../../../shiny/www/shared/bootstrap/shim/respond.min.js

  As r-cran-shiny also has a symlink to fix (see my next bug report)
you might wish to add Breaks to both packages to force the upgrade of
both at the same time : a fixed version of r-cran-rmarkdown will
need to force a reinstall (or upgrade) of r-cran-shiny in case
of respond.min.js have been overwriten. And a new version of
r-cran-shiny with the fixed symlink must be sure to not have its
files corrupted by an old version of r-cran-rmarkdown.

  Regards,
    Vincent




-- System Information:
Debian Release: bullseye/sid
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'oldstable-updates'), (500, 'unstable'), (500, 'testing'), (500, 'stable'), (500, 'oldstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386, armel, mipsel

Kernel: Linux 5.2.0-3-amd64 (SMP w/4 CPU cores)
Locale: LANG=fr_FR.utf8, LC_CTYPE=fr_FR.utf8 (charmap=UTF-8), LANGUAGE=fr_FR.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages r-cran-rmarkdown depends on:
ii  fonts-font-awesome       5.0.10+really4.7.0~dfsg-1
ii  libjs-bootstrap          3.4.1+dfsg-1
ii  libjs-highlight.js       9.12.0+dfsg1-4
ii  libjs-jquery             3.3.1~dfsg-3
ii  libjs-jquery-ui          1.12.1+dfsg-5
ii  libjs-modernizr          2.6.2+ds1-3
ii  libjs-prettify           2015.12.04+dfsg-1.1
ii  pandoc                   2.5-2+b1
ii  r-base-core [r-api-3.5]  3.6.1-6
ii  r-cran-base64enc         0.1-3-2
ii  r-cran-evaluate          0.14-1
ii  r-cran-htmltools         0.4.0-1
ii  r-cran-jsonlite          1.6+dfsg-1
ii  r-cran-knitr             1.25+dfsg-1
ii  r-cran-mime              0.7-1
ii  r-cran-shiny             1.3.2+dfsg-1
ii  r-cran-stringr           1.4.0-1
ii  r-cran-tinytex           0.16-1
ii  r-cran-xfun              0.10-1
ii  r-cran-yaml              2.2.0-1

Versions of packages r-cran-rmarkdown recommends:
ii  r-cran-testthat  2.2.1-1

Versions of packages r-cran-rmarkdown suggests:
ii  r-cran-callr     3.3.2-1
ii  r-cran-digest    0.6.21-1
pn  r-cran-dygraphs  <none>
ii  r-cran-fs        1.3.1+dfsg-1
ii  r-cran-shiny     1.3.2+dfsg-1
ii  r-cran-tibble    2.1.3-1
pn  r-cran-tufte     <none>

-- no debconf information



More information about the R-pkg-team mailing list