Shiny app works locally but dont show tables on shinyapps.io

,

I have an app that worked fine last week. I only added a column to a table. It works locally (in RStudio), but when it's online, the tables don't show. It updated without errors. I already reinstalled R (4.4.1) and RStudio, but it still doesn't work. It's a very large code, but my tables are like this

#0.-Configuramos lenguaje de la app
Sys.setlocale("LC_ALL", "es_CL.UTF-8")


#1.-Librerías-----
{
  #library(data.table)  #Lectura excel optima (fread)
  library(dplyr)       #%>% 
  library(tidyr)       #Gather
  library(ggplot2)     #Gráficos
  library(formattable) #Función formattable
  library(reactable)   #Tablas con rectatable
  library(stringr)     #Para manipular strings
  library(readr)
}
...
#consultas
  output$table1 = renderReactable({
    reactable(INFO_PANEL1()[[2]], 
              defaultPageSize = 15,
              defaultColDef = colDef(#cell = function(value){format(value, nsmall = 1)},
                                     align = "center",
                                     minWidth = 70,   
                                     header = function(value){div(style = "color: #528BB8", value)},
                                     headerStyle = list(background = "#E2E4E7")
                                     ),
              columns = list(Tipo = colDef(minWidth = 140,
                                                style = function(value,index){
                                                  if (index==1) list(background = "#E8B878")}
              ),
              `Valor` = colDef(style = function(value,index){
                if (index==1) list(background = "#E8B878")}
              )
              ), 
              bordered = T,
              highlight = T
              )

ui:

    fluidRow(
      mainPanel(width = 12,
        #Definimos los paneles
        tabsetPanel(
# Emergencia hospitalaria ----
          tabPanel("Emergencia Hospitalaria",
                   value = 1,
                   conditionalPanel(
                     condition = "input.tipo_analisis1 == 'Situación actual'",
                                      box(
                                        column(6,
                                               conditionalPanel(
                                                 condition =   "input.info_desple1.includes('Urgencia')",
                                                 br(),
                                                 br(),
                                                 p(strong("Box 1: "),"Situación actual.", style = "font-size:20px;"),
                                                 div(infoBoxOutput("Box1", width = 8), class = "custom-margin"),
                                                 br(),
                                                 br(),
                                                 p(strong("Tabla 1: "),"Requerimientos Urgencia.", style = "font-size:20px;"),
                                                 div(reactableOutput("table1", width = "90%"), class = "custom-margin2", style = "font-size:130%")
                                               )
                                               
                                        ),
                                        column(6,
                                               conditionalPanel(
                                                 condition =   "input.info_desple1.includes('Urgencia')",
                                                 br(),
                                                 br(),
                                                 p(strong("Tabla 2: "),"Especificaciones Urgencia.", style = "font-size:20px;"),
                                                 div(reactableOutput("table2", width = "90%"), class = "custom-margin2", style = "font-size:130%")
                                               ),
                                               conditionalPanel(
                                                 condition =   "input.info_desple1.includes('Dental maxilofacial')",
                                                 br(),
                                                 p(strong("Tabla 3: "),"Dental maxilofacial.", style = "font-size:20px;"),
                                                 div(reactableOutput("table6", width = "90%"), class = "custom-margin2", style = "font-size:130%")
                                               )
                                        ),
                                        width = 12)
                         ),
                   
                   conditionalPanel(
                     condition = "input.tipo_analisis1!= 'Situación actual'",
                     
                     box(h1(strong("Gráficos urgencia:")),
                         br(),
                         p("Proximamente."),
                         width = 12)
                   ),
          ),

Online:

2024-09-12T18:46:20.206525+00:00 shinyapps[11518649]: ── Column specification ────────────────────────────────────────────────────────
2024-09-12T18:46:20.212998+00:00 shinyapps[11518649]: Delimiter: ","
2024-09-12T18:46:20.217611+00:00 shinyapps[11518649]: chr  (241): l_otro_jefe, l_otro_incidenteea, l_otras_gestiones, l_observacio...
2024-09-12T18:46:20.222292+00:00 shinyapps[11518649]: dbl  (999): l_nombre_jefe, l_turno, l_movilizacion, l_incidentes___0, l_inci...
2024-09-12T18:46:20.226888+00:00 shinyapps[11518649]: lgl   (31): l_otra_un_apoyo, n_ueh_eu_mov_pctj, n_ueh_tens_mov, ust_vacunado...
2024-09-12T18:46:20.232376+00:00 shinyapps[11518649]: dttm  (39): urg_fecha, mx_fecha, ugd_fecha, ges_fecha, ucm_fecha, uti_fecha,...
2024-09-12T18:46:20.237029+00:00 shinyapps[11518649]: date   (3): fecha_entrega, l_fecha_visita, n_fecha_visita
2024-09-12T18:46:20.241516+00:00 shinyapps[11518649]: time   (2): l_hr_movilizacion, n_hr_movilizacion
2024-09-12T18:46:20.245995+00:00 shinyapps[11518649]: 
2024-09-12T18:46:20.250366+00:00 shinyapps[11518649]: ℹ Use `spec()` to retrieve the full column specification for this data.
2024-09-12T18:46:20.254699+00:00 shinyapps[11518649]: ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.

any ideas?

Just curious, what are the versions of the reactR package for both environments? I ask because I ran into a similar issue and downgrading from reactR 0.6.0 to reactR to 0.5.0 solved the issue for me.

> sessionInfo()
R version 4.4.1 (2024-06-14 ucrt)
Platform: x86_64-w64-mingw32/x64
Running under: Windows 10 x64 (build 19045)

Matrix products: default


locale:
[1] LC_COLLATE=Spanish_Chile.utf8  LC_CTYPE=Spanish_Chile.utf8   
[3] LC_MONETARY=Spanish_Chile.utf8 LC_NUMERIC=C                  
[5] LC_TIME=Spanish_Chile.utf8    

time zone: America/Santiago
tzcode source: internal

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods  
[7] base     

other attached packages:
 [1] stringr_1.5.1        formattable_0.2.1    ggplot2_3.5.1       
 [4] tidyr_1.3.1          dplyr_1.1.4          shinyjs_2.1.0       
 [7] readr_2.1.5          rsconnect_1.3.1      reactable_0.4.4     
[10] shinydashboard_0.7.2 shinyWidgets_0.8.6   shiny_1.9.1         

loaded via a namespace (and not attached):
 [1] sass_0.4.9        utf8_1.2.4        generics_0.1.3   
 [4] stringi_1.8.4     hms_1.1.3         digest_0.6.37    
 [7] magrittr_2.0.3    evaluate_0.24.0   grid_4.4.1       
[10] fastmap_1.2.0     jsonlite_1.8.8    promises_1.3.0   
[13] httr_1.4.7        purrr_1.0.2       fansi_1.0.6      
[16] scales_1.3.0      jquerylib_0.1.4   cli_3.6.3        
[19] crayon_1.5.3      rlang_1.1.4       bit64_4.0.5      
[22] munsell_0.5.1     withr_3.0.1       reactR_0.6.0     
[25] cachem_1.1.0      yaml_2.3.10       parallel_4.4.1   
[28] tools_4.4.1       tzdb_0.4.0        memoise_2.0.1    
[31] colorspace_2.1-1  httpuv_1.6.15     curl_5.2.2       
[34] vctrs_0.6.5       R6_2.5.1          mime_0.12        
[37] lifecycle_1.0.4   bit_4.0.5         htmlwidgets_1.6.4
[40] vroom_1.6.5       fontawesome_0.5.2 pkgconfig_2.0.3  
[43] pillar_1.9.0      bslib_0.8.0       later_1.3.2      
[46] gtable_0.3.5      glue_1.7.0        Rcpp_1.0.13      
[49] xfun_0.47         tibble_3.2.1      tidyselect_1.2.1 
[52] knitr_1.48        rstudioapi_0.16.0 xtable_1.8-4     
[55] htmltools_0.5.8.1 rmarkdown_2.28    compiler_4.4.1   

I'm using version 0.6.0 as well. I will try downgrading the package, but locally it works fine in Edge, Chrome, and Firefox. :face_with_hand_over_mouth:

Downgrading the reactR package to 0.4.0 works for me! (for some reason, 0.5.0 doesn't ) Thanks for posting the solution :smiling_face:

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.