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

Dev environments no longer load previous version from CDN #10196

Open
pranshukharkwal opened this issue Jun 18, 2020 · 3 comments
Open

Dev environments no longer load previous version from CDN #10196

pranshukharkwal opened this issue Jun 18, 2020 · 3 comments

Comments

@pranshukharkwal
Copy link

ALL software version info (bokeh, python, notebook, OS, browser, any other relevant packages)

Bokeh - Installed using an updated fork of https://github.com/bokeh/bokeh
Python - 3.8.3
OS - Windows 10
Browser - Google Chrome

Description of expected behavior and the observed behavior

When the environment variable "BOKEH_RESOURCES=inline" is not set, the HTML uses remote CDN BokehJS resources, and it uses a wrong URL which is
<https://cdn.bokeh.org/bokeh/release/bokeh-0+unknown.min.js
HTML fails to get these resources, and results in an empty page.

Complete, minimal, self-contained example code that reproduces the issue

If the environment variable is already set, then unset it. Then run the command.

python examples/plotting/file/iris.py

Stack traceback and/or browser JavaScript console output

Failed to load resource: the server responded with a status of 403 ()
iris.html:21 Uncaught ReferenceError: Bokeh is not defined
at iris.html:21
iris.html:49 Uncaught ReferenceError: Bokeh is not defined
at HTMLDocument.fn (iris.html:49)

Screenshots or screencasts of the bug in action

image

PS : I checked with example plots, but I guess it would have the same problem with other plots as well.

@pranshukharkwal
Copy link
Author

cc : @bryevdv

@bryevdv bryevdv changed the title [BUG] Plots don't use the correct CDN url when not using the environment variable BOKEH_RESOURCES=inline Dev environments no longer load previous version from CDN Jun 18, 2020
@bryevdv
Copy link
Member

bryevdv commented Jun 18, 2020

Setting this as discussion because I am not sure what should be done here.

Previously, when using CDN resources with a "dev" environment, Bokeh would fall back to whatever the last released version of BokehJS on CDN is. Sometimes this "works" and sometimes it does not. In the Notebook, a big banner warning is displayed waring that "this configuration is not supported and may not work".

Recently, something disturbed that. I had also noticed this but not gotten around to making an issue (thank you @pranshukharkwal). I would like to understand the change, but I am not sure that it should be "fixed" in the sense that I am not sure it's good to return to the previous behavior. I think perhaps it would be better to detect if a "dev" version of Bokeh is being used and warn (in Python or a browser alert, or both) that local dev should use inline or server resources in order to match up.

Thoughts @bokeh/dev ?

@mattpap
Copy link
Contributor

mattpap commented Jun 18, 2020

It looks like this is similar or the same issue as we had with mismatched bokeh and bokehjs versions, though I can't find the issue now (maybe there was none created).

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

No branches or pull requests

3 participants