Re: [R-pkg-devel] [EXTERNAL] Usage of internet resources in examples

2020-10-20 Thread Andy Teucher
Thanks everyone for the responses. I’m not sure why I didn’t think of wrapping the examples in try(), but I think that might be the best solution - allows the examples to be run, but won’t throw errors in R CMD check. Hong Ooi - that’s a good point though I think your example does fall more squ

Re: [R-pkg-devel] [EXTERNAL] Usage of internet resources in examples

2020-10-20 Thread Hong Ooi via R-package-devel
I set \dontrun{} on (most of) the examples in my Azure-related packages, for this very reason. They assume the user has an Azure subscription, and in any case, you don't want to be running code that could potentially cost lots of money just for kicks. The packages in question are basically all t

Re: [R-pkg-devel] Usage of internet resources in examples

2020-10-20 Thread Gábor Csárdi
On Tue, Oct 20, 2020 at 10:07 PM Ben Bolker wrote: > > > > On 10/20/20 4:51 PM, Gábor Csárdi wrote: > > On Tue, Oct 20, 2020 at 9:45 PM Ben Bolker wrote: > > [...] > >> if (testthat::skip_on_cran()) > >> > >> all seem like reasonable solutions. > > > > I don't think you can use `testthat::ski

Re: [R-pkg-devel] Usage of internet resources in examples

2020-10-20 Thread Ben Bolker
On 10/20/20 5:10 PM, Gábor Csárdi wrote: On Tue, Oct 20, 2020 at 10:07 PM Ben Bolker wrote: On 10/20/20 4:51 PM, Gábor Csárdi wrote: On Tue, Oct 20, 2020 at 9:45 PM Ben Bolker wrote: [...] if (testthat::skip_on_cran()) all seem like reasonable solutions. I don't think you can u

Re: [R-pkg-devel] Usage of internet resources in examples

2020-10-20 Thread Ben Bolker
On 10/20/20 4:51 PM, Gábor Csárdi wrote: On Tue, Oct 20, 2020 at 9:45 PM Ben Bolker wrote: [...] if (testthat::skip_on_cran()) all seem like reasonable solutions. I don't think you can use `testthat::skip_on_cran()` for this, it does not return a logical flag: ❯ isTRUE(testthat::skip

Re: [R-pkg-devel] Usage of internet resources in examples

2020-10-20 Thread Gábor Csárdi
On Tue, Oct 20, 2020 at 9:45 PM Ben Bolker wrote: [...] >if (testthat::skip_on_cran()) > > all seem like reasonable solutions. I don't think you can use `testthat::skip_on_cran()` for this, it does not return a logical flag: ❯ isTRUE(testthat::skip_on_cran()) Error: Reason: On CRAN It only

Re: [R-pkg-devel] Usage of internet resources in examples

2020-10-20 Thread Ben Bolker
Depending on what you want to do, if (interactive()) or try() (in the examples, not in the function) or if (testthat::skip_on_cran()) all seem like reasonable solutions. On 10/20/20 4:28 PM, Andy Teucher wrote: Our package bcdata (https://cran.r-project.org/package=bcdata) retri

[R-pkg-devel] Usage of internet resources in examples

2020-10-20 Thread Andy Teucher
Our package bcdata (https://cran.r-project.org/package=bcdata) retrieves public data from British Columbia data services, so the examples are dependent on successfully hitting web resources. When we initially submitted to CRAN the examples were wrapped in \dontrun{}, but we were asked to change

Re: [R-pkg-devel] detritus in temp

2020-10-20 Thread Tomas Kalibera
This was a bug in R-devel, already fixed. (specific to Unix, and only 3 R-devel revisions) Sorry for the inconvenience, Tomas On 10/20/20 4:48 PM, Cristoforo Simonetto wrote: Dear all, last week I tried to upload for the first time a package to CRAN but my submission was refused: Flavor: r-

[R-pkg-devel] detritus in temp

2020-10-20 Thread Cristoforo Simonetto
Dear all, last week I tried to upload for the first time a package to CRAN but my submission was refused: Flavor: r-devel-linux-x86_64-debian-gcc Check: for detritus in the temp directory, Result: NOTE   Found the following files/directories:     'Rscript2a22.5sWrxM' 'Rscript2a30.B2JkNS' On t

[R-pkg-devel] Python installation for automatic checks

2020-10-20 Thread Geoff Converse
Hello, I am trying to submit a package to CRAN, but it failed the auto checks at win-builder.r-project.org with errors that I do not know how to fix. My package uses Tensorflow for R, which in turn requires a Python installation of Tensorflow. I am unsure of how to get R / reticulate to find the P