R markdown pandoc document conversion failed with error 1 after updating pandoc from 1.19 to 2.4

13.3k views Asked by At

I recently installed pandoc 2.4 on Windows and the conversion failed with error 1 occurs for all knitting. I can't knit html, word, and pdf. The error says


output file: template.knitmd
pandoc.exe: template.utf8.md: openBinaryFile: does not exist (No such file or directory)
Error: pandoc document conversion failed with error 1
Execusion halted

This happens to even the raw basic template rmd file. I am using a closed network without internet connection and limited writing permission. Previously I was able to knit rmd files located in documents folder generating outputs in same location.

The sessionInfo() says


R version 3.5.1 (2018-07-02)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: windows >=8 x64 (build 9200)

Matrix products: default

locale:
[1] LC_collate=english_united states.1252 lc_ctype=english_united states.1252 lc_monetary=english_united states.1252
[4] LC_Numeric=C LC_TIME=english_united states.1252

attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] flextable_0.4.5 officer_0.3.2 knitr_1.20 rmarkdown_1.10

loaded via a namespace (and not attached):
[1] Rcpp_1.0.0 digest_0.6.18 rprojroot_1.3-2 R6_2.3.0 backports_1.1.2 magrittr_1.5 evaluate_0.12
[8]zip_1.0.0 stringi_1.2.4 gdtools_0.1.7 uuid_0.1-2 xml2_1.2.0 tools_3.5.1 stringr_1.3.1
[15] yaml_2.2.0 compiler_3.5.1 base64enc_0.1-3 htmltools_0.3.6

Any advice will be highly appreciated. (Or even ways how to change the settings back to old pandoc version without deleting the version 2.4.)

1

There are 1 answers

1
sctyner On BEST ANSWER

I have had this issue as well. Mapping the network drive where my R project was stored by following the instructions here solved the issue for me.