☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

Flaskapp with Bokeh

Community Support
Greg_Black
Greg_Black

Hi,

I’m attempting to embed a bokeh document within a flask app. I’m using script, div = components(plot) and then renderTemplate(html,script,div)

The chart makes it into my index html nicely, and the hovertool appears to be working on the localhost, however, the widgets are not active and do not update the graph accordingly. Do I need to rewrite the input widgets to respond as javascript callbacks? I believe this is possible, but I was hoping there was an easier way. Why are the widgets not working?

Full project zip is too large. Here are some snips.

Thanks,

Greg

image.png

image.png

image.png

image.png

⌁   Link to post
Bryan
Bryan

Hi,

The components function is only intended and useful for embedding standalone Bokeh content, i.e. not non-Bokeh server content with real python callbacks. For that, Bokeh server apps have to be embedded with one of the functions specifically intended for that:

  Embedding Plots and Apps — Bokeh 1.0.2 documentation

Thanks,

Bryan

···

On Dec 4, 2018, at 11:57, Greg Black <gblack686@gmail.com> wrote:

Hi,

I'm attempting to embed a bokeh document within a flask app. I'm using script, div = components(plot) and then renderTemplate(html,script,div)
The chart makes it into my index html nicely, and the hovertool appears to be working on the localhost, however, the widgets are not active and do not update the graph accordingly. Do I need to rewrite the input widgets to respond as javascript callbacks? I believe this is possible, but I was hoping there was an easier way. Why are the widgets not working?

Full project zip is too large. Here are some snips.

Thanks,
Greg
<image.png>
<image.png>
<image.png>
<image.png>

--
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 bokeh+unsubscribe@continuum.io.
To post to this group, send email to bokeh@continuum.io.
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/CAORqYh9kPpKrydh-NRO-s7V1TiwX0ick7Qc-LP1PGLPWXBah5Q%40mail.gmail.com\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

⌁   Link to post

End of archived discussion · Replies are disabled