Skip to content

Commit

Permalink
Wrap load_notebook import in version check
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr committed Sep 18, 2017
1 parent 61fa30f commit 2e6cfe8
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions holoviews/plotting/bokeh/renderer.py
Expand Up @@ -10,9 +10,7 @@
from bokeh.document import Document
from bokeh.embed import notebook_div
from bokeh.io import curdoc, show as bkshow
from bokeh.io.notebook import load_notebook
from bokeh.models import Model
from bokeh.protocol import Protocol
from bokeh.resources import CDN, INLINE
from bokeh.server.server import Server

Expand All @@ -24,6 +22,12 @@
from .util import (compute_static_patch, serialize_json, attach_periodic,
bokeh_version, compute_plot_size)

if bokeh_version > '0.12.9':
from bokeh.io.notebook import load_notebook
from bokeh.protocol import Protocol
else:
from bokeh.io import load_notebook


class BokehRenderer(Renderer):

Expand Down

0 comments on commit 2e6cfe8

Please sign in to comment.