Curdoc Showing up in Google Colab

I am trying to use the code that uses bokeh. showFretboard calls curdoc().add_root(self.layout) and I’m trying to let it appear on google colab so I use output_notebook. Is there a way for it to show up? Usually I need to host on local by doing this: bokeh serve --show Thank you so much

import os
import sys
from import output_notebook
# from seeFretboard.SeeFretboard import SeeFretboard
from seeFretboard import SeeFretboard
fretboard = SeeFretboard("v", 1, 12)

There is an example of running a Bokeh server app in a notebook here:

Basically, you need to define a factory function that generates a curdoc for your app, then pass that to show.

However please be aware that Google colab is not a standard Jupyter notebook. It is heavily modified by Google, and has restrictions and changes outside our control (e.g. limitations on Jupyter kernel access and websocket use). I cannot guarantee that Bokeh apps will function properly in colab notebooks.

Thank you Bryan, I will try that and haven’t had the time to work on the other too yet. Thanks again a lot for your help and time!

is bkapp(doc) the doc curdoc?

Yes it is what you add roots too and what backs a specific user-session.