Bokeh.client.pull_session (RuntimeError: connection to server was lost)

Hello,

I’m trying to embed a bokeh application (server) that creates and renders a scatter plot into a flask application.
I followed the documentation found at bokeh.client.session — Bokeh 2.4.2 Documentation and managed to do this for a 15K 2-dim points dataset. However, when I try to trigger the bokeh application from flask using a bigger dataset (30K points), I receive the following error ( RuntimeError: connection to server was lost ): [Screenshot-2020-02-04-at-17-05-48 — ImgBB] (Issues · bokeh/bokeh · GitHub)

See websocket_max_message_size under the reference docs for Server. Bokeh does not change the default max webscocket size defined by Tornado, but you can increase it by setting that paramter, if necessary.

Thank you for your response.
If you refer to the parameter that could be specified in serving mode (bokeh serve . —websocket-max-message size nr_bytes), I’ve already tried with nr_bytes=10^9 (1GB) and the problem still persists.

I’m afraid I don’t have any other suggestions to offer. If you provide a small, completely self-contained Minimal Reproducible Example then I am happy to run it and see if anything obvious stands out.