pandoc2 and rmarkdown interaction for metropolis #1393

Closed
opened this Issue Jul 3, 2018 · 11 comments

Projects
None yet
3 participants

eddelbuettel commented Jul 3, 2018

 When using pandoc 2.2.1 (as shipped by RStudio, here linked to ~/bin/pandoc as you see below) an otherwise fine RMarkdown presentation using the Metropolis theme fails with /home/edd/bin/pandoc +RTS -K512m -RTS minex.utf8.md --to beamer \ --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash \ --output minex.tex --variable theme=metropolis --highlight-style tango \ --pdf-engine xelatex --self-contained tlmgr search --file --global '/ucharcat.sty' Cannot determine type of tlpdb from /home/edd/texmf! cannot setup TLPDB in /home/edd/texmf at /usr/bin/tlmgr line 6071. ! LaTeX Error: File ucharcat.sty' not found.  The file is of course present, and running with the older pandoc version 1.19.2.1 works fine (as shown below). This happens with both the CRAN and the development versions of RMarkdown. I used the following file minex.Rm: --- author: Some Author title: A Talk subtitle: Subtitle date: 1 Jan 2018 output: beamer_presentation: keep_tex: no theme: metropolis latex_engine: xelatex classoption: compress fontsize: 12pt --- {r, setup, include=FALSE} knitr::opts_chunk$set(cache=TRUE)  # New Slide ## New Title  Once I remove the softlink, all is well: edd@rob:~$ render.r minex.Rmd processing file: minex.Rmd |...................... | 33% ordinary text without R code |........................................... | 67% label: setup (with options) List of 1 $include: logi FALSE |.................................................................| 100% ordinary text without R code output file: minex.knit.md /usr/bin/pandoc +RTS -K512m -RTS minex.utf8.md --to beamer --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output minex.tex --variable theme=metropolis --highlight-style tango --latex-engine xelatex --self-contained Output created: minex.pdf edd@rob:~$  As I would like to move to pandoc2 at some point, it would nice if this could be addressed. Could this be a preference for tinytex over a standard (working, complete, ...) texlive installation? Ubuntu 17.10, R 3.4.4, everything from CRAN current
Member

norbusan commented Jul 4, 2018

 i am suprised that loading unicode-math on Ubuntu 17.04 does not work. As @yihui said, this should have been fixed back in Feb 2016, so it is suprising to me. @eddelbuettel if you have Ubuntu 17.04 running, could you run a minimal test file \documentclass{article} \usepackage{unicode-math} \begin{document} Hello World \end{document}  and run it with xelatex -recorder and send me the .fls and .log file (or attach it here). In current TL this file is not loaded at all.
Author

eddelbuettel commented Jul 4, 2018

 Did I say 17.10? I meant 17.04. I am also suprised it failed. edd@rob:/tmp$xelatex -recorder foo.tex This is XeTeX, Version 3.14159265-2.6-0.99998 (TeX Live 2017/Debian) (preloaded format=xelatex) restricted \write18 enabled. entering extended mode (./foo.tex LaTeX2e <2017-04-15> Babel <3.12> and hyphenation patterns for 7 language(s) loaded. (/usr/share/texlive/texmf-dist/tex/latex/base/article.cls Document Class: article 2014/09/29 v1.4h Standard LaTeX document class (/usr/share/texlive/texmf-dist/tex/latex/base/size10.clo)) (/usr/share/texlive/texmf-dist/tex/latex/unicode-math/unicode-math.sty (/usr/share/texlive/texmf-dist/tex/generic/ifxetex/ifxetex.sty) (/usr/share/texlive/texmf-dist/tex/generic/oberdiek/ifluatex.sty) (/usr/share/texlive/texmf-dist/tex/latex/l3kernel/expl3.sty (/usr/share/texlive/texmf-dist/tex/latex/l3kernel/expl3-code.tex) (/usr/share/texlive/texmf-dist/tex/latex/l3kernel/l3xdvipdfmx.def)) ! LaTeX Error: File ucharcat.sty' not found. Type X to quit or to proceed, or enter new name. (Default extension: sty) Enter file name: (/usr/share/texlive/texmf-dist/tex/latex/l3packages/xparse/xparse.sty) (/usr/share/texlive/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty) (/usr/share/texlive/texmf-dist/tex/latex/fontspec/fontspec.sty (/usr/share/texlive/texmf-dist/tex/latex/fontspec/fontspec-xetex.sty (/usr/share/texlive/texmf-dist/tex/latex/base/fontenc.sty (/usr/share/texlive/texmf-dist/tex/latex/base/tuenc.def)) (/usr/share/texlive/texmf-dist/tex/latex/fontspec/fontspec.cfg))) (/usr/share/texlive/texmf-dist/tex/latex/base/fix-cm.sty (/usr/share/texlive/texmf-dist/tex/latex/base/ts1enc.def)) (/usr/share/texlive/texmf-dist/tex/latex/filehook/filehook.sty) (/usr/share/texlive/texmf-dist/tex/latex/unicode-math/unicode-math-xetex.sty (/usr/share/texlive/texmf-dist/tex/latex/unicode-math/unicode-math-table.tex))) No file foo.aux. [1] (./foo.aux) ) Output written on foo.pdf (1 page). Transcript written on foo.log. edd@rob:/tmp$  I could have sworn locate ucharcat.sty found it days ago when I looked for this, now it doesn't. I may have looked at packages.debian.org when I should have looked at Ubuntu, In any event, I just learned that it is in texlive-luatex which I had not installed. I have it now, and with that rmarkdown works as well with pandoc2: My life is good again. This was a false alert: I was the luser not being able to find ucharcat.sty. The only remaining thought is to maybe extend the depends of some other package to texlive-luatex.

norbusan commented Jul 5, 2018

 The dependency was added due to the bug report mentioned above, and that was in 2/2016, so it should have been in Ubuntu 17.04 ...
Author

eddelbuettel commented Jul 5, 2018

 That is indeed weird, but the more embarassing issue is that fell over a missing file in a missing package -- usually it is simple enough to find the missing file. Someone I convinced myself it was present when it wasn't.... Anyway, may help the next guy who stumbles over this and googles it: install texlive-luatex.