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

don't restrict shinyapps.io from previous deployment check in deploymentTarget #933

Merged
merged 6 commits into from
Jul 27, 2023

Conversation

mslynch
Copy link
Contributor

@mslynch mslynch commented Jul 26, 2023

No description provided.

Copy link
Contributor

@aronatkins aronatkins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Once you prove that this works, NEWS and test, please.

@mslynch mslynch marked this pull request as ready for review July 26, 2023 19:55
app_dir <- withr::local_tempdir()
target <- deploymentTarget(app_dir, appName = "my_app")
expect_equal(target$appId, 123)
for (server in c("example.com", "shinyapps.io")) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is best done with a helper function and two invocations of that test function -- that will help us understand which condition is failing. Something like:

confirm_existing_application_use <- function(server) {
    # innards of loop
}
test_that("can find existing application on server & use it", {
  confirm_existing_application_use("example.com")
})
test_that("can find existing application on shinyapps.io & use it", {
  confirm_existing_application_use("shinyapps.io")
})

@hadley - do you have different recommendations?

Copy link
Contributor

@mbaynton mbaynton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This tests out properly for me. Running interactively I am prompted whether to redeploy to the application that was found, running noninteractively it assumes that's what I want, which is consistent with prior behavior.

@aronatkins aronatkins merged commit 74a2cf7 into main Jul 27, 2023
@aronatkins aronatkins deleted the 932/previous-deployment-check-shinyappsio branch July 27, 2023 01:21
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 this pull request may close these issues.

Regression: re-deploys to shinyapps.io from stateless environments fail
3 participants