r-lib / pkgload

Simulate installing and loading a package
http://pkgload.r-lib.org
58 stars 46 forks source link

load_all() creates .Random.seed when compilation is needed #272

Closed MichaelChirico closed 6 months ago

MichaelChirico commented 6 months ago

In R --vanilla

ls(all=TRUE)
# character(0)

# any (?) package with src/ code, I've tried roxygen2, Rcpp, and data.table
#   but _not_ on lint, which doesn't have src/ code
pkgload::load_all()

ls(all=TRUE)
# [1] ".Random.seed"

Is that intended/unavoidable behavior? It may harm reproducibility. OTOH, I can't think of a place where this causes an issue, it's just something I noticed when tinkering around on another problem. So don't feel obligated to devote too much effort to this.

MichaelChirico commented 6 months ago

Moving this to {pkgbuild}