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

deployApp() should throw a warning if appMode is inferred to be static #1097

Open
gadenbuie opened this issue Aug 2, 2024 · 0 comments
Open

Comments

@gadenbuie
Copy link
Member

Someone who calls deployApp() is expecting to deploy an interactive application, but deployApp() might incorrectly infer the application is static. As a user, I picked deployApp() over deployDoc() because I wanted to deploy an application.

> quarto::quarto_publish_app(
+   "dashboard.qmd",
+   name = "app-name",
+   server = "connect.example.com"
+ )
── Preparing for deployment ───────────────────────────────────────────────────────────────
✔ Deploying "app-name" using "server: connect.example.com / username: gadenbuie"
ℹ Creating application on server...
✔ Created application with id 10
✔ Created 911,909b bundle
ℹ Uploading bundle...
✔ Uploaded bundle with id 13
── Deploying to server ────────────────────────────────────────────────────────────────────
Building static content...
Launching static content...
── Deployment complete ────────────────────────────────────────────────────────────────────
✔ Successfully deployed to https://connect.example.com/content/4c3ede83-2870-4f1b-bf20-ca2aa8c51714/

When this happens, it's not immediately clear how to fix it and I think many people, myself included, will look for problems in the source document rather than investigating arguments to deployApp().

The solution is to explicitly set appMode to one of "shiny", "rmd-shiny", or "quarto-shiny"-- or even"static"` if a static application is truly desired. A warning message could easily instruct the user how to make this change.

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

1 participant