CRAN check error: `pandoc version xxx or higher is required and was not found`

I'm getting the following error on the CRAN package check page of my package:

Running the tests in ‘tests/testthat.R’ failed.
Last 13 lines of output:
── Error ('test-icon.R:26:5'): orcid() makes orcid icon metadata ───────────────
Error: pandoc version 1.12.3 or higher is required and was not found (see the help page ?rmarkdown::pandoc_available).

I didn't change that file from the previous version which initially passed CRAN checks so I'd assume it's a CRAN problem. Just in case, is there anything I can do to fix it apart from not running that test on CRAN or if rmarkdown isn't installed? I've found quite a few things online about the error but couldn't find a clear answer to my question.

I'd recommend skipping indeed.

I see rmarkdown itself defined a test helper: skip_if_not_pandoc(). It's used in rmarkdown tests obviously as is skip_on_cran(). I'm writing this because if rmarkdown skips some tests on CRAN, it's not surprising your package will need to. :smiley_cat:

2 Likes

Alright, thanks. skip_on_cran() might be the easiest solution then. Any idea why that same test previously passed CRAN checks?

No, sorry! Maybe it's just a temporary installation problem (answer inspired by an answer of Yihui's years ago).

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.