-
Notifications
You must be signed in to change notification settings - Fork 133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shiny Server: Could not find a root 'DESCRIPTION' file that starts with '^Package' #1127
Comments
I've found a solution by commenting out the load_all() and options() calls. $ cat app.R
# Launch the ShinyApp (Do not remove this comment)
# To deploy, run: rsconnect::deployApp()
# Or use the blue button on top of this file
# pkgload::load_all(export_all = FALSE,helpers = FALSE,attach_testthat = FALSE)
# options( "golem.app.prod" = TRUE)
mygolempackage::run_app() # add parameters here (if any) I'm still a novice regarding package development so I don't understand why golem::add_shinyserver_file(pkg = get_golem_wd(), open = TRUE) adds load_all to the app.R. Could the documentation be updated to explain what it is for and how to setup the package on a shiny-server so when it is deployed, load_all() works? |
Hello @JustGitting , The The error seems to say that the function is unable to find the Have you unzipped the |
Hi @ArthurData, Sorry I hadn't got back to you, Christmas and all... Indeed, I didn't copy any package source files to the app.R directory. I had assumed it wasn't necessary as I had installed the package via install.packages(). It makes sense now, but it wasn't clear from the documentation that the original app.R created by golem::add_shinyserver_file() includes extra function calls for development purposes. Could the documentation be updated to note the Is it possible to add an option to golem::add_*() that disables the creation of the extra function calls in app.R? e.g. |
Hey @JustGitting, Thanks for reporting 🫶 The output of the function is the following, the last line indeed signals that the whole package should be uploaded to the server.
That being said, I feel like this is not enough, and that the I'm opening a new issue to track this fix. |
Describe the bug
I've built a very simple shiny app with the Golem framework that successfully runs locally within Rstudio. However, when I try deploying it on a shiny-server, I get the following error in the logs.
To Reproduce
I followed the advice deploying a golem package on a shiny-server #145 using option 2 in the discussion.
Steps to reproduce the behavior:
mygolempackage.tar.gz
to the shiny server.sudo su - -c "R -e \"install.packages('/home/user/Downloads/mygolempackage.0.0.1.tar.gz', repos=NULL)\""
/srv/shiny-server/mygolempackage/
The app.R contains the following code:
Expected behavior
Application should work.
Screenshots
I get the following error message on the webpage:
Server session info
Any suggestions would be appreciated as I may have done something wrong along the way.
The text was updated successfully, but these errors were encountered: