部署Shiny应用或flexdashboard到shinyapps.io时出错的解决求助
Error when deploying "Hello Shiny" to shinyapps.io: replacement has 1 row, data has 0
I'm trying to deploy the official Shiny tutorial example "Hello Shiny" to my shinyapps.io account, but I keep hitting this error:
Error in `$<-.data.frame`(`*tmp*`, "config_url", value = "https://www.shinyapps.io/admin/#/application/") : replacement has 1 row, data has 0
Here's the full code for my app.R file:
library(shiny) ui <- fluidPage( titlePanel("Hello Shiny!"), sidebarLayout( sidebarPanel( sliderInput(inputId = "bins", label = "Number of bins:", min = 1, max = 50, value = 30) ), mainPanel( plotOutput(outputId = "distPlot") ) ) ) server <- function(input, output) { output$distPlot <- renderPlot({ x <- faithful$waiting bins <- seq(min(x), max(x), length.out = input$bins + 1) hist(x, breaks = bins, col = "#75AADB", border = "white", xlab = "Waiting time to next eruption (in mins)", main = "Histogram of waiting times") }) } shinyApp(ui = ui, server = server)
Additional Context
- The app runs flawlessly on my local machine.
- I'm working in a proxy environment and have followed all official configuration guidelines for shinyapps.io and the
rsconnectpackage. - Operating System: Windows 10
- All relevant packages (
shiny,rsconnect,rmarkdown) are updated to their latest available versions. - I get the exact same error when attempting to deploy a flexdashboard that uses a Shiny runtime.
Here's my sessionInfo() output for reference:
Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows >= 8 x64 (build 9200) Matrix products: default locale: [1] LC_COLLATE=German_Germany.1252 LC_CTYPE=German_Germany.1252 LC_MONETARY=German_Germany.1252 [4] LC_NUMERIC=C LC_TIME=German_Germany.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base other attached packages: [1] shiny_1.4.0.2 loaded via a namespace (and not attached): [1] Rcpp_1.0.4 digest_0.6.25 later_1.0.0 mime_0.9 R6_2.4.1 xtable_1.8-4 jsonlite_1.6.1 [8] magrittr_1.5 rlang_0.4.5 curl_4.3 promises_1.1.0 Cairo_1.5-10 tools_3.5.2 httpuv_1.5.2 [15] yaml_2.2.1 rsconnect_0.8.16 fastmap_1.0.1 compiler_3.5.2 askpass_1.1 htmltools_0.4.0 openssl_1.3
I've been troubleshooting this for a while without luck, so any tips or solutions would be greatly appreciated. Thanks in advance!
内容的提问来源于stack exchange,提问作者MxNl




