Skip to content

Commit

Permalink
Simplified Bokeh Document creation
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr committed Jan 6, 2016
1 parent fb8c568 commit 05f2bda
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions holoviews/plotting/bokeh/renderer.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
old_bokeh = True
except ImportError:
from bokeh.core.json_encoder import serialize_json
from bokeh.model import _find_some_document
old_bokeh = False


Expand Down Expand Up @@ -68,10 +67,8 @@ def __call__(self, obj, fmt=None):

def figure_data(self, plot, fmt='html', **kwargs):
if not old_bokeh:
doc = _find_some_document([plot.state])
if not doc:
doc = Document()
doc.add_root(plot.state)
doc = Document()
doc.add_root(plot.state)
comms_target = str(uuid.uuid4())
doc.last_comms_target = comms_target
div = notebook_div(plot.state, comms_target)
Expand Down

0 comments on commit 05f2bda

Please sign in to comment.