Hi #RStats. I often wish we had an R option/env var to indicate we're offline. Code could then *nicely* fall back to offline solutions. I lieu of a standard, can we come up with one here? I start by proposing:
$ export R_OFFLINE=true
> options(offline=TRUE)
Other suggestions?
3
4
13
Or if anyone knows of non-R standards for this, please share. Maybe there's already some de facto standard for this in Linux, macOS, or MS Windows?
1
2
I have `isConnected` in package `dang` which does the trick---by trying to resolve Google (as a default, can be changed) and to open the page.
As it relies only on base R itshould be portable enough. I am sure lots of people have similar helper functions.
#rstats
1
2
5
In theory, R_OFFLINE may work. In practice, someone who should have set ot may then have failed to do so.
In practice, base::url() is orthogonal to all this, does not require other resources, folks, or coordination--and thus seems to work for me. #rstats
Apr 19, 2021 · 12:11 AM UTC
1
1


