CRAN maintainers now require that examples not be boxed in by the \dontrun{
tags. Since most of rOpenSci's packages retrieve data from the web, this can be problematic, especially if the API requires a key. But in cases where a key isn't required, I'm fine with allowing the examples to run.
When I use dplyr::rbind_all(list_name)
over do.call(rbind, list_name)
to combine data.frames
, I get this issue when running a devtools::check()
.
> ### ** Examples
>
> data_by_code <- aw_code(code = "casent0104669")
Warning in rbind_all(image_data) :
Unequal factor levels: coercing to character
Warning in rbind_all(image_data) :
Unequal factor levels: coercing to character
Warning in rbind_all(image_data) :
Unequal factor levels: coercing to character
Warning in rbind_all(image_data) :
Unequal factor levels: coercing to character
Error: incompatible type (data index: 3, column: 'img1', was collecting: character (dplyr::Collecter_Impl<16>), incompatible with data of type: INTSXP
Execution halted
Error: Command failed (1)
git clone -b dplyr_issues https://github.com/ropensci/AntWeb.git
cd AntWeb
R
library(devtools)
check()
However, when the examples in master
are set to not run, check
runs fine.
git clone -b master https://github.com/ropensci/AntWeb.git
cd AntWeb
R
library(devtools)
check()
Exposing examples without using dplyr::rbind_all
also works fine and passes all checks.
git clone -b no-dplyr https://github.com/ropensci/AntWeb.git
cd AntWeb
R
library(devtools)
check()
Wat? CRAN is removing \dontrun?