You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
The progress UI provided by Shiny works correctly when reload = TRUE in the shiny.run_app() function. However, when reload = FALSE, the progress bar either doesn't update properly or doesn't appear at all, and only updates once the function has finished executing.
After testing various scenarios, it seems that the reload argument is the most relevant factor. Is there a way to ensure the progress bar works correctly even when reload = FALSE?
test code
from shiny import reactive
from shiny.express import input, render, ui
import time
ui.input_action_button("button", "Compute")
@render.text
@reactive.event(input.button)
def compute():
with ui.Progress(min=1, max=15) as p:
p.set(message="Calculation in progress", detail="This may take a while...")
for i in range(1, 15):
p.set(i, message="Computing")
time.sleep(0.1)
# Normally use time.sleep() instead, but it doesn't yet work in Pyodide.
# https://github.com/pyodide/pyodide/issues/2354
return "Done computing!"
The text was updated successfully, but these errors were encountered:
Hello,
The progress UI provided by Shiny works correctly when reload = TRUE in the shiny.run_app() function. However, when reload = FALSE, the progress bar either doesn't update properly or doesn't appear at all, and only updates once the function has finished executing.
After testing various scenarios, it seems that the reload argument is the most relevant factor. Is there a way to ensure the progress bar works correctly even when reload = FALSE?
test code
from shiny import reactive
from shiny.express import input, render, ui
import time
ui.input_action_button("button", "Compute")
@render.text
@reactive.event(input.button)
def compute():
with ui.Progress(min=1, max=15) as p:
p.set(message="Calculation in progress", detail="This may take a while...")
The text was updated successfully, but these errors were encountered: