Closed kadyb closed 4 years ago
Hi - I will take a look at in the next two days.
Log from rcmdcheck
:
- checking files in ‘vignettes’ ... NOTE The following directory looks like a leftover from 'knitr': ‘figure’
- checking running R code from vignettes ... SKIPPED
- checking re-building of vignette outputs ... SKIPPED
Log from pkgdown
:
-- Building articles ---------------------------------------------------------- Writing 'articles/index.html' Reading 'vignettes/articles/geodb_description.Rmd' Writing 'articles/articles/geodb_description.html' Reading 'vignettes/orthophotomap.Rmd' Writing 'articles/orthophotomap.html' == DONE ========================================
So, let's try:
rcmdcheck
_pkgdown.yml
eia
images are directly in the vignettes folder.stars
, because raster
takes a long time to process (~6 min for me with data downloading).Ad4 - try https://github.com/kadyb/rgugik/pull/31
It works but under the figures there are unnecessary captions like "plot of chunk unnamed-chunk-9".
I will try to make it work tomorrow.
Now we use stars
instead of raster
- rasters processing is immediate (use proxy
).
I suppose if we apply to CRAN, we will have to change vignettes to articles (so they won't generated by CRAN). It only takes to change the location of the files.
Why? Cannot we just submit as it is? (CRAN will only regerate .Rmd files which do not download anything)
If so, OK. I thought we had to use source .Rmd files that are fully executable (with data downloading).
Nope. The whole idea now is to knit the .Rmd.orig
file locally (before submitting to CRAN), which creates a new .Rmd
file. This new file contains all data downloading results (nothing it being downloaded there).
Next issues:
I think this step in PRECOMPILE.R
is unnecessary because we are building vignettes in pkgdown
on GitHub Actions:
library(devtools)
build_vignettes()
Right?
Maybe before knit("vignettes/orthophotomap.Rmd.orig", "vignettes/orthophotomap.Rmd")
we should use setwd()
to save images in the same folder? This is not recommended, but we can try. More info.
Also, we can try remove "--no-vignettes" argument from rcmdcheck
and we'll see if it really works.
opts_knit$set(root.dir = "vignettes/"
, but without any success.It seems to be working fine.
setwd("vignettes/")
knit("orthophotomap.Rmd.orig", "orthophotomap.Rmd")
I set it up in 94e12d4.
Can we prerender vignettes instead of building them with
pkgdown
? There is the same problem that requests from GitHub are blocked in functionsorto_request
andDEM_request
. https://ropensci.org/technotes/2019/12/08/precompute-vignettes/Second problem is that I added "--no-vignettes" argument to
rcmdcheck
, but still trying to build vignettes. I also removed "--as-cran" argument but without success.