Problem with rendering {shiny} app: Error: C stack usage 1914576 is too close to the limit
When rendering {shiny} apps using VSCode-r, I see the following errer:
Error: C stack usage 1914576 is too close to the limit
However, this issue does not happen when I render the {shiny} app via an external R terminal.
Current Result (when executed in VSCode R terminal)

Expected Result (when executed in an external R terminal)
# Load
library(shiny)
# Front-end user interface
ui <- fluidPage(
titlePanel("Shiny App"),
sidebarLayout(
sidebarPanel(
"Sidebar Panel",
numericInput(inputId = "num", "Type any integer:", value = 50),
selectInput(inputId = "color", "Choose your color for histogram:", choices = colors(), selected = "blue")
),
mainPanel(
"Main panel",
plotOutput(outputId = "histogram")
)
)
)
# Back-end logic
server <- function(input, output, session) {
num <- reactive(input$num)
color <- reactive(input$color)
output$histogram <- renderPlot(hist(rnorm(num()), col = color()))
}
# Execute
shinyApp(ui, server)
#>
#> Listening on http://127.0.0.1:8575

Created on 2022-08-04 by the reprex package (v2.0.1)
Session info
sessioninfo::session_info()
#> ─ Session info ───────────────────────────────────────────────────────────────
#> setting value
#> version R version 4.2.1 (2022-06-23 ucrt)
#> os Windows 10 x64 (build 22000)
#> system x86_64, mingw32
#> ui RTerm
#> language (EN)
#> collate English_United States.utf8
#> ctype English_United States.utf8
#> tz America/Chicago
#> date 2022-08-04
#> pandoc 2.18 @ C:/PROGRA~3/CHOCOL~1/bin/ (via rmarkdown)
#>
#> ─ Packages ───────────────────────────────────────────────────────────────────
#> package * version date (UTC) lib source
#> bslib 0.4.0 2022-07-16 [1] CRAN (R 4.2.1)
#> cachem 1.0.6 2021-08-19 [1] CRAN (R 4.2.0)
#> callr 3.7.1 2022-07-13 [1] CRAN (R 4.2.1)
#> chromote 0.1.0 2022-04-19 [1] CRAN (R 4.2.1)
#> cli 3.3.0 2022-04-25 [1] CRAN (R 4.2.0)
#> curl 4.3.2 2021-06-23 [1] CRAN (R 4.2.0)
#> digest 0.6.29 2021-12-01 [1] CRAN (R 4.2.0)
#> ellipsis 0.3.2 2021-04-29 [1] CRAN (R 4.2.0)
#> evaluate 0.15 2022-02-18 [1] CRAN (R 4.2.0)
#> fansi 1.0.3 2022-03-24 [1] CRAN (R 4.2.0)
#> fastmap 1.1.0 2021-01-25 [1] CRAN (R 4.2.0)
#> fs 1.5.2 2021-12-08 [1] CRAN (R 4.2.0)
#> glue 1.6.2 2022-02-24 [1] CRAN (R 4.2.0)
#> highr 0.9 2021-04-16 [1] CRAN (R 4.2.0)
#> htmltools 0.5.3 2022-07-18 [1] CRAN (R 4.2.1)
#> httpuv 1.6.5 2022-01-05 [1] CRAN (R 4.2.0)
#> httr 1.4.3 2022-05-04 [1] CRAN (R 4.2.0)
#> jquerylib 0.1.4 2021-04-26 [1] CRAN (R 4.2.0)
#> jsonlite 1.8.0 2022-02-22 [1] CRAN (R 4.2.0)
#> knitr 1.39 2022-04-26 [1] CRAN (R 4.2.0)
#> later 1.3.0 2021-08-18 [1] CRAN (R 4.2.0)
#> lifecycle 1.0.1 2021-09-24 [1] CRAN (R 4.2.0)
#> magrittr 2.0.3 2022-03-30 [1] CRAN (R 4.2.0)
#> memoise 2.0.1 2021-11-26 [1] CRAN (R 4.2.0)
#> mime 0.12 2021-09-28 [1] CRAN (R 4.2.0)
#> pillar 1.8.0 2022-07-18 [1] CRAN (R 4.2.1)
#> pkgconfig 2.0.3 2019-09-22 [1] CRAN (R 4.2.0)
#> processx 3.7.0 2022-07-07 [1] CRAN (R 4.2.1)
#> promises 1.2.0.1 2021-02-11 [1] CRAN (R 4.2.0)
#> ps 1.7.1 2022-06-18 [1] CRAN (R 4.2.0)
#> purrr 0.3.4 2020-04-17 [1] CRAN (R 4.2.0)
#> R.cache 0.16.0 2022-07-21 [1] CRAN (R 4.2.1)
#> R.methodsS3 1.8.2 2022-06-13 [1] CRAN (R 4.2.0)
#> R.oo 1.25.0 2022-06-12 [1] CRAN (R 4.2.0)
#> R.utils 2.12.0 2022-06-28 [1] CRAN (R 4.2.1)
#> R6 2.5.1 2021-08-19 [1] CRAN (R 4.2.0)
#> ragg 1.2.2 2022-02-21 [1] CRAN (R 4.2.0)
#> Rcpp 1.0.9 2022-07-08 [1] CRAN (R 4.2.1)
#> reprex 2.0.1 2021-08-05 [1] CRAN (R 4.2.0)
#> rlang 1.0.4 2022-07-12 [1] CRAN (R 4.2.1)
#> rmarkdown 2.14.3 2022-06-24 [1] Github (rstudio/rmarkdown@d23e479)
#> sass 0.4.2 2022-07-16 [1] CRAN (R 4.2.1)
#> sessioninfo 1.2.2 2021-12-06 [1] CRAN (R 4.2.0)
#> shiny * 1.7.2.9000 2022-07-25 [1] Github (rstudio/shiny@c21ba0b)
#> stringi 1.7.8 2022-07-11 [1] CRAN (R 4.2.1)
#> stringr 1.4.0 2019-02-10 [1] CRAN (R 4.2.0)
#> styler 1.7.0.9001 2022-07-26 [1] Github (r-lib/styler@3414b81)
#> systemfonts 1.0.4 2022-02-11 [1] CRAN (R 4.2.0)
#> textshaping 0.3.6 2021-10-13 [1] CRAN (R 4.2.0)
#> tibble 3.1.8 2022-07-22 [1] CRAN (R 4.2.1)
#> utf8 1.2.2 2021-07-24 [1] CRAN (R 4.2.0)
#> vctrs 0.4.1 2022-04-13 [1] CRAN (R 4.2.0)
#> webshot 0.5.3 2022-04-14 [1] CRAN (R 4.2.0)
#> webshot2 0.1.0 2022-05-18 [1] CRAN (R 4.2.1)
#> websocket 1.4.1 2021-08-18 [1] CRAN (R 4.2.0)
#> withr 2.5.0 2022-03-03 [1] CRAN (R 4.2.0)
#> xfun 0.31 2022-05-10 [1] CRAN (R 4.2.0)
#> xml2 1.3.3 2021-11-30 [1] CRAN (R 4.2.0)
#> xtable 1.8-4 2019-04-21 [1] CRAN (R 4.2.0)
#> yaml 2.3.5 2022-02-21 [1] CRAN (R 4.2.0)
#>
#> [1] C:/Program Files/R/R-4.2.1/library
#>
#> ──────────────────────────────────────────────────────────────────────────────
VSCode Info
Version: 1.70.0 (system setup) Commit: da76f93349a72022ca4670c1b84860304616aaa2 Date: 2022-08-04T04:38:16.462Z Electron: 18.3.5 Chromium: 100.0.4896.160 Node.js: 16.13.2 V8: 10.0.139.17-electron.0 OS: Windows_NT x64 10.0.22000
I cannot reproduce the problem on Windows, macOS and Linux.
Thanks for testing, @renkun-ken ! I have just found that this issue occurs when I use radian console on Windows; the original R term does not throw an error. Would you mind testing this again at your best convenience?
@jooyoungseo , if that is the case then it is a likely an issue with radian and not the vscode-R extension. In which case sorry to be a pain but would you mind filing a ticket instead with the radian project: https://github.com/randy3k/radian
@gowerc -- Thanks! I have created an issue there.