File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -363,10 +363,7 @@ async def invoke_on_restore_callbacks():
363
363
364
364
# Run the on_restored function after the flush cycle completes and
365
365
# information is sent to the client.
366
- # Update: Using `on_flush` to have the callbacks populate the output message
367
- # queue going to the browser. If `on_flushed` is used, the messages stall
368
- # until the next `on_flushed` invocation.
369
- @session .on_flush
366
+ @session .on_flushed
370
367
async def invoke_on_restored_callbacks ():
371
368
if self ._on_restored_callbacks .count () == 0 :
372
369
return
Original file line number Diff line number Diff line change @@ -664,6 +664,11 @@ def verify_state(expected_state: ConnectionState) -> None:
664
664
with session_context (self ):
665
665
self .app .server (self .input , self .output , self )
666
666
667
+ # TODO: Remove this call to reactive_flush() once https://github.com/posit-dev/py-shiny/issues/1889 is fixed
668
+ # Workaround: Any `on_flushed()` calls from bookmark's `on_restored()` will be flushed here
669
+ if self .bookmark .store != "disable" :
670
+ await reactive_flush ()
671
+
667
672
elif message_obj ["method" ] == "update" :
668
673
verify_state (ConnectionState .Running )
669
674
You can’t perform that action at this time.
0 commit comments