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

rsconnect.packrat does not apply to push-button deployment #935

Closed
aronatkins opened this issue Jul 26, 2023 · 3 comments · Fixed by #937
Closed

rsconnect.packrat does not apply to push-button deployment #935

aronatkins opened this issue Jul 26, 2023 · 3 comments · Fixed by #937
Assignees

Comments

@aronatkins
Copy link
Contributor

From a project that does not use renv (a very simple Shiny application will suffice):

options(rsconnect.packrat = TRUE)

Deploy the project using push-button deployment. The "Deploy" pane will show:

ℹ Capturing R dependencies with renv

Deploying the same project using the console:

reconnect::deployApp()

we see the output:

ℹ Capturing R dependencies with packrat

It appears that not all R options make their way to the deploy R session.

@aronatkins
Copy link
Contributor Author

@kevinushey What's our best option to have a setting from the R console apply in the R deployment session? Is an environment variable more likely to work than an R option? Are only certain options / environment variables propagated?

@kevinushey
Copy link
Contributor

Environment variables would be the most reliable, since those should be propagated automatically -- AFAIK we don't try to propagate any specific options (except maybe repos).

@aronatkins aronatkins assigned aronatkins and unassigned hadley Jul 27, 2023
aronatkins added a commit that referenced this issue Jul 27, 2023
Environment variables are visible in the RStudio IDE R session used for
push-button deployment. Not all R options are mirrored into that session.

Fixes #935
Fixes #936
aronatkins added a commit that referenced this issue Jul 27, 2023
Environment variables are visible in the RStudio IDE R session used for
push-button deployment. Not all R options are mirrored into that session.

These settings indicate that packrat should be used, even in the presence
of an renv.lock. When using packrat, the renv directory and renv.lock file
are removed from the bundle directory, as would happen prior to rsconnect 1.0.0.

Fixes #935
Fixes #936
aronatkins added a commit that referenced this issue Jul 28, 2023
* prefer RSCONNECT_PACKRAT over rsconnect.packrat

Environment variables are visible in the RStudio IDE R session used for
push-button deployment. Not all R options are mirrored into that session.

These settings indicate that packrat should be used, even in the presence
of an renv.lock. When using packrat, the renv directory and renv.lock file
are removed from the bundle directory, as would happen prior to rsconnect 1.0.0.

Fixes #935
Fixes #936

* spelling

* trailing whitespace lint

* feedback
@tyner
Copy link

tyner commented Mar 13, 2024

Note: ?rsconnect::appDependencies metions options(rsconnect.packrat = TRUE) but there is no mention of the environment variable approach.

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

Successfully merging a pull request may close this issue.

4 participants