From 0a7970e74df44a2d24740f12e5b49f91bcd4a60d Mon Sep 17 00:00:00 2001 From: Philipp Rudiger Date: Wed, 15 May 2024 12:45:23 +0200 Subject: [PATCH] Ensure model changes are applied while session is starting --- panel/io/state.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/panel/io/state.py b/panel/io/state.py index a884d98c52..81b4772de3 100644 --- a/panel/io/state.py +++ b/panel/io/state.py @@ -278,8 +278,9 @@ def _unblocked(self, doc: Document) -> bool: 3. The application has fully loaded and the Websocket is open. """ return ( - doc is self.curdoc and self._thread_id in (self._current_thread, None) and - (not doc or not doc.session_context or self._loaded.get(doc)) + doc is self.curdoc and + self._thread_id in (self._current_thread, None) and + (not (doc and doc.session_context and doc.session_context.session) or self._loaded.get(doc)) ) @param.depends('_busy_counter', watch=True)