rhino icon indicating copy to clipboard operation
rhino copied to clipboard

Don't require R session restart after `rhino::init()`

Open TymekDev opened this issue 3 years ago • 0 comments

Problem

During init() we create .Rprofile which contains some important settings required to run the app. Without sourcing it the app fails to start:

rhino::init()
shiny::runApp()
## Error in box::use(r/main) : 
##  unable to load module “r/main”

Sourcing .Rprofile, running options(box.path = file.path(getwd(), "app")), or restarting R sessions fixes this behavior.

Possible solutions

Source .Rprofile after init(). This might cause issues, e.g. with renv - we need to test this thoroughly.

Perhaps we should just clearly inform users that they should restart R (maybe in addition to sourcing .Rprofile).

TymekDev avatar Mar 04 '22 18:03 TymekDev