Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bokeh Port Error #37

Closed
koaning opened this issue Oct 28, 2020 · 3 comments
Closed

Bokeh Port Error #37

koaning opened this issue Oct 28, 2020 · 3 comments

Comments

@koaning
Copy link
Owner

koaning commented Oct 28, 2020

Sometimes I hit this error:

ERROR:bokeh.server.views.ws:Refusing websocket connection from Origin 'http://localhost:8889';                       use --allow-websocket-origin=localhost:8889 or set BOKEH_ALLOW_WS_ORIGIN=localhost:8889 to permit this; currently we allow origins {'localhost:8888'}
WARNING:tornado.access:403 GET /ws (::1) 1.65ms

Would be nice to get an automated fix for this.

@koaning
Copy link
Owner Author

koaning commented Oct 28, 2020

This is related to something
bokeh cannot do without explicit permission from jupyter. It can't be fixed by this library but I added something to the FAQ to explain.

@nthomsencph
Copy link
Contributor

nthomsencph commented Oct 5, 2021

Hi,
Spent quite some time on this issue. Couldn't get around displaying the charts in in VSC notebooks as per ##67
Exporting the variable in ~/.bashrc didn't work either for me for some reason.
When encountering this issue, I solved it by running jupyter lab instead and explicitly setting

import os os.environ["BOKEH_ALLOW_WS_ORIGIN"] = "localhost:8889"

And then running
charts = InteractiveCharts(df.loc[lambda d: d['label'] == ''], labels = ['group']) charts.add_chart(x = "dim1", y = "dim2")
normally, as Vincent does in PyData Riyadh

Hope this helps

@koaning, perhaps we can add this (quite hacky) fix to the examples/fag?

@koaning
Copy link
Owner Author

koaning commented Oct 5, 2021

@nthomsencph feel free to make a PR :) !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants