Bokeh WebSocket connection closes in under 24hr for no reason

Hi,

I use Bokeh to create live dashboards for the company - I have a backend script that pulls data from GA every 24hr and this is read by a Bokeh script that then plots the data.

Unfortunately, the WebSocket connection now closes in under 24hr… as such, it requires that I refresh the web browser in order for the new data points to be correctly displayed. I had been using Tornado v 4.3 which reduced the amount of time this error (I guess it’s not technically an error?) displayed - the dashboards were typically running for 4-5 days before the WebSocket connection was closing. However, this seemed to stop working and I updated Tornado to 4.5.3 and now this error appears to display in less than 24hours.

Has anyone come across a solution to this (that doesn’t require me refreshing the web page periodically?)

The libraries and versions are as follows:

Bokeh 0.12.7

Python 3.6.2

Tornado 4.5.2

The exact message shown in terminal is ‘WebSocket connection closed: code=None, reason=None’

Thanks in advance

Hi,

By default Bokeh server sessions will expire after a period of inactivity. Perhaps you simply want to increase these values appropriately:

  https://bokeh.pydata.org/en/latest/docs/reference/command/subcommands/serve.html#session-expiration-options

Thanks,

Bryan

···

On Jan 12, 2018, at 01:53, [email protected] wrote:

Hi,

I use Bokeh to create live dashboards for the company - I have a backend script that pulls data from GA every 24hr and this is read by a Bokeh script that then plots the data.

Unfortunately, the WebSocket connection now closes in under 24hr... as such, it requires that I refresh the web browser in order for the new data points to be correctly displayed. I had been using Tornado v 4.3 which reduced the amount of time this error (I guess it's not technically an error?) displayed - the dashboards were typically running for 4-5 days before the WebSocket connection was closing. However, this seemed to stop working and I updated Tornado to 4.5.3 and now this error appears to display in less than 24hours.

Has anyone come across a solution to this (that doesn't require me refreshing the web page periodically?)

The libraries and versions are as follows:
Bokeh 0.12.7
Python 3.6.2
Tornado 4.5.2

The exact message shown in terminal is 'WebSocket connection closed: code=None, reason=None'

Thanks in advance

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/c2726d99-4767-42a3-aa20-b30cb362a093%40continuum.io.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Thanks Bryan,

I’ll try that and let you know how it goes :slight_smile:

···

On Tuesday, January 16, 2018 at 9:28:17 PM UTC, Bryan Van de ven wrote:

Hi,

By default Bokeh server sessions will expire after a period of inactivity. Perhaps you simply want to increase these values appropriately:

    [https://bokeh.pydata.org/en/latest/docs/reference/command/subcommands/serve.html#session-expiration-options](https://bokeh.pydata.org/en/latest/docs/reference/command/subcommands/serve.html#session-expiration-options)

Thanks,

Bryan

On Jan 12, 2018, at 01:53, [email protected] wrote:

Hi,

I use Bokeh to create live dashboards for the company - I have a backend script that pulls data from GA every 24hr and this is read by a Bokeh script that then plots the data.

Unfortunately, the WebSocket connection now closes in under 24hr… as such, it requires that I refresh the web browser in order for the new data points to be correctly displayed. I had been using Tornado v 4.3 which reduced the amount of time this error (I guess it’s not technically an error?) displayed - the dashboards were typically running for 4-5 days before the WebSocket connection was closing. However, this seemed to stop working and I updated Tornado to 4.5.3 and now this error appears to display in less than 24hours.

Has anyone come across a solution to this (that doesn’t require me refreshing the web page periodically?)

The libraries and versions are as follows:

Bokeh 0.12.7

Python 3.6.2
Tornado 4.5.2

The exact message shown in terminal is ‘WebSocket connection closed: code=None, reason=None’

Thanks in advance


You received this message because you are subscribed to the Google Groups “Bokeh Discussion - Public” group.

To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].

To post to this group, send email to [email protected].

To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/c2726d99-4767-42a3-aa20-b30cb362a093%40continuum.io.

For more options, visit https://groups.google.com/a/continuum.io/d/optout.