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

deploy failure dev shiny #213

Closed
TNRiley opened this issue Nov 8, 2024 · 9 comments
Closed

deploy failure dev shiny #213

TNRiley opened this issue Nov 8, 2024 · 9 comments
Assignees
Labels
Bug Something isn't working Shiny Application

Comments

@TNRiley
Copy link
Collaborator

TNRiley commented Nov 8, 2024

Inline comment causing deployment failure

@TNRiley TNRiley added the Bug Something isn't working label Nov 8, 2024
@TNRiley TNRiley self-assigned this Nov 8, 2024
@TNRiley
Copy link
Collaborator Author

TNRiley commented Nov 8, 2024

fixed the inline comment, but have further issues regarding CRAN mirrors. Haven't been able to solve.

Deploy error

Error in contrib.url(repos, type) :
trying to use CRAN without setting a mirror
Calls: install.packages -> startsWith -> contrib.url
Execution halted
Error: Process completed with exit code 1.

@LukasWallrich
Copy link
Collaborator

Sounds like we have "install.packages" somewhere in the code - that should not anywhere

@LukasWallrich
Copy link
Collaborator

Ignore that comment - clearly the issue is in the action, not our code

@LukasWallrich
Copy link
Collaborator

Currently, we are setting up R in two ways -

    uses: r-lib/actions/setup-r@v2

AND

    uses: eddelbuettel/github-actions/r-ci-setup@master

I believe we still use the second version even after your change (which allows for much faster package install) - but should not set up both. I will try to track down how we can change the version in the r-ci version, and see if that fixes the CRAN issue (that version uses an inbuilt CRAN, so we should not change it)

@LukasWallrich
Copy link
Collaborator

I asked the r2u author whether we can specify the R version: eddelbuettel/r2u#74 - that approach is faster and more robust, so I would not want to rebuild the action for now.

R 4.2.2 was released 8 days ago, and shinyapps.io usually wants to support new versions within a couple of days - so the problem will go away temporarily very soon anyway, but we should obviously know how to fix this when it recurrs.

@LukasWallrich
Copy link
Collaborator

It cannot be done with r2u, and I would not want to fix the R version in our automated deploy script as that would mean updating that regularly. Instead, I added a manual deploy script that we can use when shinyapps.io and the latest R diverge. To run that, go to Actions and select document-and-deploy-manual, click on Run workflow, select whether you want to run it for main or dev and specify the R version (the current default works this time round). It takes twice as long as the usual deploy, but gets the job done.

@LukasWallrich
Copy link
Collaborator

@TNRiley hope that makes sense - let me know if you run into further issues / have better ideas.

@LukasWallrich
Copy link
Collaborator

LukasWallrich commented Nov 10, 2024

I realized that the performance catches up when the action is run more than once (due to caching) and that it is better to have only one version - so I switched to this, and we now always deploy to shinyapps.io with the previous R version. That should be robust and easier to maintain than two actions. @TNRiley so no manual deploy is needed.

@TNRiley
Copy link
Collaborator Author

TNRiley commented Nov 10, 2024

I realized that the performance catches up when the action is run more than once (due to caching) and that it is better to have only one version - so I switched to this, and we now always deploy to shinyapps.io with the previous R version. That should be robust and easier to maintain than two actions. @TNRiley so no manual deploy is needed.

sounds good. much of this deployment stuff is over my head as I've not yet played around with it. Appreciate you working on this and resolving it. I see the latest now has the fixes I had made.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working Shiny Application
Projects
None yet
Development

No branches or pull requests

2 participants