From the information provided, I believe the problem is the syntax in the invocation of the server. There are two specific problems.
--args command-line switch is the last option in the bokeh serve call and is used to send arguments to your specific application(s) not the bokeh server mechanism.
This is documented in the bokeh reference document here, excerpting the relevant section.
If you would like to pass command line arguments to Bokeh applications, you can pass the
--args option as the LAST option on the command line:
bokeh serve app_script.py myapp.py --args foo bar --baz
Everything that follows
--args will be included in
sys.argv when the application runs. In this case, when
myapp.py executes, the contents of
sys.argv will be
['myapp.py', 'foo', 'bar', '--baz'], consistent with standard Python expectations for
Note that if multiple scripts or directories are provided, they all receive the same set of command line arguments (if any) given by
- The command-line option to set the websocket max message size uses hyphens rather than dashes in the option name, e.g.
SOLUTION: Putting it all together, the syntax for your app should be the following.
bokeh serve --show myApp.py --websocket-max-message-size=500000000
And you should see something like this in the server console, which confirms the max websocket size has been set to something other than a default value.
% bokeh serve --show myApp.py --websocket-max-message-size=500000000
2021-07-14 10:27:57,190 Starting Bokeh server version 2.3.2 (running on Tornado 6.1)
2021-07-14 10:27:57,191 Torndado websocket_max_message_size set to 500000000 bytes (476.84 MB)
2021-07-14 10:27:57,191 User authentication hooks NOT provided (default user enabled)
2021-07-14 10:27:57,193 Bokeh app running at: http://localhost:5006/myApp
2021-07-14 10:27:57,193 Starting Bokeh server with process id: 6523
2021-07-14 10:27:57,539 WebSocket connection opened
2021-07-14 10:27:57,540 ServerConnection created
Hope this helps / makes sense.