New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compiling PDF with pandoc version 2.0.1 fails... #1184

Closed
JeffreyRacine opened this Issue Nov 1, 2017 · 8 comments

Comments

Projects
None yet
4 participants
@JeffreyRacine

JeffreyRacine commented Nov 1, 2017

Greetings,

Tried pandoc 2.0.1 releases Oct 31, compiling PDF documents fails... using the template for a new markdown document in RStudio...

> library(rmarkdown)
> pandoc_version()
[1] ‘2.0.1’

Error message is

/usr/local/bin/pandoc +RTS -K512m -RTS Untitled.utf8.md --to latex --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output Untitled.pdf --template /Users/jracine/Library/R/rmarkdown/rmd/latex/default-1.17.0.2.tex --highlight-style tango --pdf-engine /opt/local/bin/pdflatex --variable graphics=yes --variable 'geometry:margin=1in' 
pdf-engine /opt/local/bin/pdflatex is not compatible with output format latex
Error: pandoc document conversion failed with error 1
Execution halted

Thanks!

> sessionInfo()
R version 3.4.2 (2017-09-28)
Platform: x86_64-apple-darwin17.0.0/x86_64 (64-bit)
Running under: macOS High Sierra 10.13.1

Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRlapack.dylib

locale:
[1] en_CA.UTF-8/en_CA.UTF-8/en_CA.UTF-8/C/en_CA.UTF-8/en_CA.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] MASS_7.3-47 np_0.60-3  

loaded via a namespace (and not attached):
 [1] Rcpp_0.12.13         lattice_0.20-35      digest_0.6.12        rprojroot_1.2        grid_3.4.2           backports_1.1.1     
 [7] MatrixModels_0.4-1   magrittr_1.5         evaluate_0.10.1      stringi_1.1.5        SparseM_1.77         cubature_1.3-11     
[13] Matrix_1.2-11        boot_1.3-20          rmarkdown_1.6.0.9007 tools_3.4.2          stringr_1.2.0        yaml_2.1.14         
[19] compiler_3.4.2       htmltools_0.3.6      knitr_1.17.9         quantreg_5.34       
> 

@JeffreyRacine JeffreyRacine changed the title from Compiling PDF with panic version 2.0.1 fails... to Compiling PDF with pandoc version 2.0.1 fails... Nov 1, 2017

@rundel

This comment has been minimized.

rundel commented Nov 1, 2017

Compiling HTML files is also failing under pandoc 2.0.1 (installed via homebrew). Using the following as test.Rmd

---
title: Hello World
output: html_document
---

A sample document.

```{r}
1 + 1  # a line of code
```

Another paragraph.

I get the following error when attempting to render:

$ Rscript -e "library(rmarkdown);render('test.Rmd')"


processing file: test.Rmd
  |......................                                           |  33%
  ordinary text without R code

  |...........................................                      |  67%
label: unnamed-chunk-1
  |.................................................................| 100%
  ordinary text without R code


output file: test.knit.md

/usr/local/bin/pandoc +RTS -K512m -RTS test.utf8.md --to html --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output test.html --smart --email-obfuscation none --self-contained --standalone --section-divs --template /usr/local/lib/R/3.4/site-library/rmarkdown/rmd/h/default.html --no-highlight --variable highlightjs=1 --variable 'theme:bootstrap' --include-in-header /var/folders/k8/4z3ndjqd0nj1xczfp4ktnnzc0000gp/T//RtmpzgUqQT/rmarkdown-str152e650fb7b73.html --mathjax --variable 'mathjax-url:https://mathjax.rstudio.com/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML'
--smart/-S has been removed.  Use +smart or -smart extension instead.
For example: pandoc -f markdown+smart -t markdown-smart.
Try pandoc --help for more information.
Error: pandoc document conversion failed with error 2
Execution halted

sessionInfo():

R version 3.4.2 (2017-09-28)
Platform: x86_64-apple-darwin17.0.0 (64-bit)
Running under: macOS High Sierra 10.13.1

Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLAPACK.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  base

other attached packages:
[1] rmarkdown_1.6

loaded via a namespace (and not attached):
 [1] compiler_3.4.2  backports_1.1.1 magrittr_1.5    rprojroot_1.2
 [5] tools_3.4.2     htmltools_0.3.6 Rcpp_0.12.13    stringi_1.1.5
 [9] knitr_1.17      methods_3.4.2   stringr_1.2.0   digest_0.6.12
[13] evaluate_0.10.1
@yihui

This comment has been minimized.

Member

yihui commented Nov 1, 2017

Duplicate of #1120

devtools::install_github("rstudio/rmarkdown")

Or if you use RStudio, you can remove Pandoc brew remove pandoc, since RStudio has a built-in version of Pandoc (1.19).

@ajaypillarisetti

This comment has been minimized.

ajaypillarisetti commented Nov 20, 2017

I'm having the same set of issues, using the biclust example. My error is:

output file: /private/var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T/RtmpfVrO5h/index.knit.md

/usr/local/bin/pandoc +RTS -K512m -RTS /private/var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T/RtmpfVrO5h/index.utf8.md --to html --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output /private/var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T/RtmpfVrO5h/file42978482471.html --email-obfuscation none --standalone --section-divs --template /Library/Frameworks/R.framework/Versions/3.3/Resources/library/flexdashboard/rmarkdown/templates/flex_dashboard/resources/default.html --include-in-header /var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T//RtmpfVrO5h/rmarkdown-str4294850b468.html --id-prefix section- --variable 'theme:cosmo' --mathjax --variable 'mathjax-url:https://mathjax.rstudio.com/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML' --include-in-header /var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T//RtmpfVrO5h/file4295a90f257html --include-after-body /var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T//RtmpfVrO5h/file429484f8b07.html --highlight-style pygments --include-before-body /var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T//RtmpfVrO5h/file42962165c34.html --include-after-body /var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T//RtmpfVrO5h/file42929ff8c3b.html 
pandoc: /var/folders/ms/66l1s3gd2xdf4s8nt0hkp6k00000gn/T//RtmpfVrO5h/rmarkdown-str4294850b468.html: openBinaryFile: does not exist (No such file or directory)
Warning: Error in : pandoc document conversion failed with error 1

sessionInfo():

R version 3.3.3 (2017-03-06)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: macOS  10.13.1

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] grid      stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] biclust_1.2.0       lattice_0.20-34     colorspace_1.3-2    MASS_7.3-45         ggplot2_2.2.1      
 [6] DT_0.2              plyr_1.8.4          readxl_1.0.0        data.table_1.10.4-3 shiny_1.0.5        
[11] rmarkdown_1.8      

loaded via a namespace (and not attached):
 [1] Rcpp_0.12.13      cellranger_1.1.0  tools_3.3.3       digest_0.6.12     jsonlite_1.5      evaluate_0.10.1  
 [7] tibble_1.3.4      gtable_0.2.0      rlang_0.1.4       parallel_3.3.3    yaml_2.1.14       stringr_1.2.0    
[13] knitr_1.17        htmlwidgets_0.9   stats4_3.3.3      rprojroot_1.2     flexdashboard_0.5 R6_2.2.2         
[19] magrittr_1.5      backports_1.1.1   scales_0.5.0      htmltools_0.3.6   modeltools_0.2-21 flexclust_1.3-4  
[25] mime_0.5          xtable_1.8-2      httpuv_1.3.5      stringi_1.1.6     lazyeval_0.2.1    munsell_0.4.3

I've also tried R 3.4.2.

This all arose as a result of getting a new laptop and having to get everything up and running again. The old laptop (and another development machine) are remotely accessible, so relatively okay for now. Any guidance or help would be greatly appreciated. Many sincere thanks for all the work you all do.

@yihui

This comment has been minimized.

Member

yihui commented Nov 20, 2017

@ajaypillarisetti Have you tried the development versions of flexdashboard and knitr?

devtools::install_github(c('yihui/knitr', 'rstudio/flexdashboard'))
@ajaypillarisetti

This comment has been minimized.

ajaypillarisetti commented Nov 20, 2017

Thanks @yihui. I have tried the dev versions without any luck and have tried using both pandoc installed via brew (2.0.2) and the RStudio pandoc (1.19.2.1).

@yihui

This comment has been minimized.

Member

yihui commented Nov 21, 2017

@ajaypillarisetti I can reproduce it with the following minimal example, and will try to fix it ASAP (sounds like a problem caused by #820). Thanks for the report!

---
title: "Test"
output: 
  flexdashboard::flex_dashboard:
    source_code: embed
runtime: shiny
---

a

yihui added a commit that referenced this issue Nov 21, 2017

fix the issue reported by @ajaypillarisetti in #1184: should wait til…
…l the top-level render() exits to clean up temporary files
@yihui

This comment has been minimized.

Member

yihui commented Nov 21, 2017

@ajaypillarisetti Fixed now (this has nothing to do with the version of Pandoc). You can install the development version via

devtools::install_github('rstudio/rmarkdown')

Thanks again!

@ajaypillarisetti

This comment has been minimized.

ajaypillarisetti commented Nov 21, 2017

@yihui Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment