Skip to content
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 installing tar from cellar not working #1674

Closed
drmowinckels opened this issue Sep 5, 2023 · 4 comments
Closed

renv installing tar from cellar not working #1674

drmowinckels opened this issue Sep 5, 2023 · 4 comments

Comments

@drmowinckels
Copy link

drmowinckels commented Sep 5, 2023

Hi.

i'm sorry that my reprex is lacking here, but I hope I can still explain well enough to get help/ideas on how to solve this issue.

I'm working in an airgapped environment, with full CRAN syncing daily. Because its airgapped, I prepared the stringi tar following the no internet access instructions in the stringi install instructions. I was able to follow renv instructions on installing tars from the cellar, and the cellar tar is being discovered and renv is trying install from there.

however, this install fails, for what to me looks like clang setup issues. However, installing this tar with install.packages("renv/cellar/package_x.y.z..tar.gz", repos = NULL) works just fine. Is there some flag or settings for renv I need to fix to make this work?

image

SessionInfo (screenshot as exporting text from environment it tricky)
image

@drmowinckels
Copy link
Author

Sorry, managed to solve my initial issue (by a little magic, mainly getting a new tar).

However, I'm still struggling to get renv::restore or renv::repair to successfully install from cellar.
So, while I can successfully install stringi from the tar through direct command, if I try to run renv::restore or renv::repair from another environment (I have another dev environment using R 3.6.0), it fails, because its still trying to install stringi with the ICU data packets from online, which are not available. But the tar in the cellar should no longer contain information about doing that, as I removed it as per stringi instructions.

image

I fully acknowledge that all these problems might be super specific to my context and not something renv can or should deal with. Especially since I seem to be having somewhat variable issues.

@kevinushey
Copy link
Collaborator

But the tar in the cellar should no longer contain information about doing that, as I removed it as per stringi instructions.

Are you able to confirm whether or not renv is indeed using the copy of stringi in the Cellar when attempting to install the package? If a "manual" installation of the package works, I would expect renv to work as well if using the same package, since renv is just calling R CMD INSTALL under the hood.

@drmowinckels
Copy link
Author

after a long and winding road, I have finally managed to get things working.

  1. renv was indeed getting from cellar. in fact, renv all the time did exactly as it should.
  2. stringi did not act as expected. There were some conditions that were not met on the 3.6.1 host, so it was trying to get another icu that was not bundled as expected.
    To resolve this, we downloaded the icu zip, placed it in the cellar, and added a little code snippet to the Rprofile to add configure arguments about the location of the icu file given R is run on a certain host.

Now, it all works as a charm, and I have a learned a great deal about renv, that makes me even more appreciative of it.

@kevinushey
Copy link
Collaborator

Thanks! I'm glad to hear you were able to get unblocked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants