I am writing an R package and using Travis for Continuous Integration. Tests and R CMD CHECK pass locally and for 3 versions of R under Linux (oldrel, release, and devel). All three versions fail under macOS with no information in the Travis logs:

R CMD check fail logs
0.01s$ for name in $(find "${RCHECK_DIR}" -type f -name "*fail");do echo ">>> Filename: ${name} <<<";cat ${name};done
R CMD check log logs

I checked in the Travis logs that all the tests I wrote in testthat fail. The Travis tests once passed for both Linux and macOS, so I could dissect the code changes to detect the issue, but ideally I could use something more direct and faster than groping in the dark waiting for an answer from Travis.

Any ideas?


If you are using the recommended setting for R packages of upgrading warnings to errors, i.e. with this line in .travis.yml:

warnings_are_errors: true

then the place to look is the previous heading in the Travis log, called Checking package.

Example of problem with missing font

In my case, the Travis log under the heading Checking package showed that the inconsolata font was missing, so the vignettes failed to build:

* checking PDF version of manual ... WARNING
LaTeX errors when creating PDF version.
This typically indicates Rd problems.
LaTeX errors found:
! LaTeX Error: File `inconsolata.sty' not found.
Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: sty)
! Emergency stop.
<read *> 

l.276 ^^M

!  ==> Fatal error occurred, no output PDF file produced!
* checking PDF version of manual without hyperrefs or index ... ERROR
Status: 1 ERROR, 1 WARNING

This caused an error for LaTeX, a warning for R, and an error for Travis.

Solution to problem

In my case, the problem was due to Travis using TeXLive 2019 and the CTAN mirrors having yet to update to 2019.

The issue appears in the Travis R community forum:

might be related to the recent switch to TexLive-2019 as the LaTeX package manager seems to fail finding inconsolata in the repository.


It looks to me like the mirror chosen was has not updated to 2019, so I think this will resolve itself naturally when the mirrors catch up. If not I can look into it.

In the meantime, I solved it by forcing a previous version of TeXLive with a downgrade to OSX 10.12 in .travis.yml:

# macOS 10.12 version
osx_image: xcode9.2

See this Travis page for the correspondence between XCode and OSX versions and the original thread in DevOps StackExchange.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.