-
Notifications
You must be signed in to change notification settings - Fork 154
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
renv github dependencies don't work with rsconnect::deployApp #308
Comments
Does this work if you install the development version of Packrat? |
I don't think so. Here's what I tried: git clone git@github.com:generalui/renv-rsconnect-github.git
cd renv-rsconnect-github
open renv-rsconnect-github.Rproj Then in RStudio: renv::restore(confirm=FALSE)
install.packages("devtools")
devtools::install_github("rstudio/packrat")
rsconnect::deployApp()
# fails in a NEW way: GithubUsername must be specified for GitHub package source If I do the steps exactly as I've just specified. I get a new error. Here is the full listing of the new error:
HOWEVER, if I do things in a slightly different order, as show below, I get the error I originally mentioned: Start with a fresh git clone as per the steps above, then in RStudio: renv::restore(confirm=FALSE)
rsconnect::deployApp()
# fails in the old way: unable to satisfy package: concordanceIndex (0.1)
install.packages("devtools")
devtools::install_github("rstudio/packrat")
rsconnect::deployApp()
# fails in the old way: unable to satisfy package: concordanceIndex (0.1) Versions:
|
I've made some changes to the development version of |
Thanks for the quick patch! I updated to 0.9.2-14. Unfortunately, it didn't seem to work. However, I think I have an insight into what is going on. I inspected the DESCRIPTION file for concodanceIndex in renv/library both before and after I ran Here is the DESCRIPTION file as installed by renv:
And here is the DESCRIPTION file as installed by devtools::install_github:
On a hunch, I restored everything to the pure-renv solution (git cloned a fresh directory, then It seems rsconnect requires those Github entries... |
AND... I think that's what you just fixed. I just realized I had to clear my RENV cache for it to work properly. When I did, and then did a renv::restore, it added toe Github fields. Awesome! Thanks so much for the fix! |
Hi @shanebdavis, I'm facing a similar issue, I have migrated from packrat. I can deploy with packrat without any error but with renv I'm getting a similar error you mentioned above. Can you explain how you solved it? |
@mohang13 did you find a solution? |
I have a large existing application I am converting to using Renv. Mostly it's gone great, but there are a couple of direct github dependencies. Locally, it's no problem. Renv installs and restores them fine. However, when I attempt to deploy with rsconnect::deployApp, they fail.
I created a simple repo to demo the problem with full documentation:
In short, I have a tiny app which deploys, but when I run the following:
And starting using the library in the source (e.g.
concordanceIndex::concordanceIndex
), the deploy fails:Versions:
I have a workaround at the moment from the doc on this page: https://docs.rstudio.com/shinyapps.io/getting-started.html
However, whatever devtools::install_github does isn't reflected in changes in my repository. Every time someone checks out my repository, they have to manually run devtools::install_github for every github dependency.
The original renv::install + renv::snapshot should be all I need to use a github dependency, right?
The text was updated successfully, but these errors were encountered: