-
Notifications
You must be signed in to change notification settings - Fork 83
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
Changes in renv/rsconnect - now getting "Local" packages in our CI/CD pipeline #1004
Comments
@slodge-work - Is this project managed by renv? How is R.Brandy tracked in your renv.lock? @kevinushey - Do you have any suggestions, here? What is the best way to record that the devtools installed from-zip package is also available in the repository? |
I've been digging some more. Each repo is renv controlled, yes. I think this block of code is what controls Repository and Source for non-Local packages - https://github.com/rstudio/rsconnect/blob/41907afefe219a5e00496c0ba99746eca38fbf01/R/bundlePackageRenv.R#L94C1-L120C1 Interestingly, for most of our apps (ones which have multiple packages - including some from outside the current repo), then the Connect installation succeeds - it seems Connect tries the bad
I've also looked back at other deployments which were working a month ago... and some of those have manifest entries starting e.g.
... so maybe we were just "lucky" this has been working so well all along... I'm beginning to think I should just bite the bullet and change our build system so it deploys the newly built package(s) from our CRAN instead of from the local disk copy.... although if there is an answer to "What is the best way to record that the devtools installed from-zip package is also available in the repository?" then maybe I'll reconsider... Thanks for looking, but please don't worry too much... I can try to get this working "properly" using CRANs. |
The interpretation of I'm surprised that we are leaving @hadley - It feels as if we are missing some path in |
It's not great, but the escape hatch that
where you'd fill in the list with the fields you'd normally have in the lockfile entry. |
Thanks @kevinushey I gave that a go, but it looks like this override is only used for renv::restore() workflows - https://github.com/search?q=repo%3Arstudio%2Frenv%20renv_lockfile_override&type=code This has given me better understanding of where "Local" is used - and an idea of how to "override" (aka "hack") insider our own build system though... so I think I'll go with that, especially given the conceptual problems that the PR hit. |
Workaround implemented - we now find the DESCRIPTION file of the locally installed packages and remove the remote lines:
At some point we might need to do something better... e.g. I might need to work out the network and security paths to do proper CRAN installing within our build system. But for now 👍 So closing - thanks all |
Not entirely sure this is an issue - but this seems like the best place to get advice/answers - so please forgive me asking here.
For many of our apps, reports and apis, our repos and CI/CD pipelines work by:
This pipeline's been working pretty well for a couple of years and is very stable.
Right now I'm looking at a breaking change in our pipelines following upgrading rsconnect to 1.x. What I'm seeing is that the currently built package is being picked up in the auto-generated manifest.json as:
The problem here are the line:
These cause the Connect deployment step to fail with lots of messages like...
Under previous versions of rsconnect (which I guess were less renv based) the manifest was written as:
which just worked (TM)
I'm currently wondering if there's anything I can toggle inside rsconnect/renv to make it pick up that this package should be looked up in CRAN...
If not then I can change the build system it so that it installs from our CRAN server(s) before doing the deployment. I'm just hesitating before doing this second option, though, as there are subtleties there (and as I've broken production stability enough already this month!)
Just wondering if anyone has any other suggestions/ideas...
The text was updated successfully, but these errors were encountered: