Skip to content

Progress bar properties cannot be cleared by setting NULL #4070

@chlebowa

Description

@chlebowa

Progress$set(value = NULL) should remove the progress bar but it does not.

message and detail can be hidden by setting "" or "NA" but the bar persists.

example app
library(shiny)

ui <- fluidPage()
srv <- function(input, output) {
  prog <- Progress$new()
  prog$set(message = "old message", value = 0)
  Sys.sleep(2)
  prog$set(message = "new message", value = 1)
  Sys.sleep(2)
  prog$set(message = NULL, value = NULL)
  Sys.sleep(2)
  prog$close()
}

shinyApp(ui, srv)
session info
R version 4.4.0 (2024-04-24 ucrt)
Platform: x86_64-w64-mingw32/x64
Running under: Windows 10 x64 (build 19045)

Matrix products: default


locale:
[1] LC_COLLATE=English_United States.utf8 
[2] LC_CTYPE=English_United States.utf8
[3] LC_MONETARY=English_United States.utf8
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.utf8

time zone: Europe/Warsaw
tzcode source: internal

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

other attached packages:
[1] shiny_1.8.1.1

loaded via a namespace (and not attached):
 [1] digest_0.6.35     later_1.3.2       R6_2.5.1          httpuv_1.6.15
 [5] fastmap_1.2.0     magrittr_2.0.3    cachem_1.1.0      memoise_2.0.1
 [9] htmltools_0.5.8.1 lifecycle_1.0.4   promises_1.3.0    cli_3.6.2
[13] xtable_1.8-4      sass_0.4.9        jquerylib_0.1.4   compiler_4.4.0
[17] tools_4.4.0       bslib_0.7.0       mime_0.12         Rcpp_1.0.12      
[21] rlang_1.1.3       jsonlite_1.8.8

Related to #3148

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions