pkgdown icon indicating copy to clipboard operation
pkgdown copied to clipboard

Cannot build vignettes with `devel = TRUE` because build_article() runs a new process

Open renozao opened this issue 1 year ago • 0 comments

When running build_site() with argument devel = TRUE, the vignettes are built under a new process instead of using the current process where the package has already been loaded with devtools::load_all() . This failure is very likely to happen since a vignette would typically call library() early on to load the package itself.

I believe the issue comes from the fact that argument new_process is not passed down to build_article():

Suggestion:

  • Add argument new_process to build_articles() here: https://github.com/r-lib/pkgdown/blob/main/R/build-articles.R#L196
  • Pass argument new_process to build_article() here: https://github.com/r-lib/pkgdown/blob/main/R/build-articles.R#L214
  • Pass argument new_process here based on value of argument devel: https://github.com/r-lib/pkgdown/blob/main/R/build.R#L452

renozao avatar Nov 08 '24 09:11 renozao