Error message in notebook when running Explicit Path graph example from User Guide
See original GitHub issueWhen I take the Explicit Plot example in the graph section of the User Guide, https://bokeh.pydata.org/en/latest/docs/user_guide/graph.html, and display in a notebook I get the following message on the show(plot)
:
E-1001 (BAD_COLUMN_NAME): Glyph refers to nonexistent column name: fill_color [renderer: GlyphRenderer(id='2ee90517-57dc-45e6-8169-288256a4d6cf', …)]
The plot still displays as expected.
ALL software version info (bokeh, python, notebook, OS, browser, any other relevant packages)
Bokeh: 0.12.9 Python: 3.6
Description of expected behavior and the observed behavior
Plot displays as it does now, but the error message does not display.
Complete, minimal, self-contained example code that reproduces the issue
import math
from bokeh.io import show, output_notebook
from bokeh.plotting import figure
from bokeh.models import GraphRenderer, StaticLayoutProvider, Oval
from bokeh.palettes import Spectral8
output_notebook()
N = 8
node_indices = list(range(N))
plot = figure(title="Graph Layout Demonstration", x_range=(-1.1,1.1), y_range=(-1.1,1.1),
tools="", toolbar_location=None)
graph = GraphRenderer()
graph.node_renderer.data_source.data = dict(
index=node_indices,
fill_color=Spectral8)
graph.node_renderer.glyph = Oval(height=0.1, width=0.2, fill_color="fill_color")
graph.edge_renderer.data_source.data = dict(
start=[0]*N,
end=node_indices)
### start of layout code
circ = [i*2*math.pi/8 for i in node_indices]
x = [math.cos(i) for i in circ]
y = [math.sin(i) for i in circ]
graph_layout = dict(zip(node_indices, zip(x, y)))
graph.layout_provider = StaticLayoutProvider(graph_layout=graph_layout)
### Draw quadratic bezier paths
def bezier(start, end, control, steps):
return [(1-s)**2*start + 2*(1-s)*s*control + s**2*end for s in steps]
xs, ys = [], []
sx, sy = graph_layout[0]
steps = [i/100. for i in range(100)]
for node_index in node_indices:
ex, ey = graph_layout[node_index]
xs.append(bezier(sx, ex, 0, steps))
ys.append(bezier(sy, ey, 0, steps))
graph.edge_renderer.data_source.data['xs'] = xs
graph.edge_renderer.data_source.data['ys'] = ys
plot.renderers.append(graph)
show(plot)
Stack traceback and/or browser JavaScript console output
None
Screenshots or screencasts of the bug in action
Issue Analytics
- State:
- Created 6 years ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
Why is pydot unable to find GraphViz's executables in ...
The problem is that the path to GraphViz was not found by the pydot module as shown in the traceback: 'GraphViz\'s executables not...
Read more >Tutorial: Advanced Jupyter Notebooks - Dataquest
Exploring topics like logging, macros, running external code, and Jupyter extensions. Seeing how to enhance charts with Seaborn, beautify ...
Read more >Track machine learning training runs | Databricks on AWS
Logging example notebook; Organize training runs with MLflow experiments; Manage training code with MLflow runs; Access the MLflow tracking ...
Read more >Working with Jupyter Notebooks & JupyterLab — Ray 2.2.0
CLI's such as ray exec and ray submit fit the second use case better. 4. Forward the ports. Assuming the Notebook runs on...
Read more >On writing clean Jupyter notebooks - Ploomber
Ironically, the ability to interact with our data rapidly (modify code cells, run, and repeat) is the exact reason why a notebook may...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@mattpap - Restarting ipython Kernel in my Anaconda flushed the old data Columns.
The problem is with field name validator in: https://github.com/bokeh/bokeh/blob/bbdf7bd63a255da7a99b7583bc4846684d6163fb/bokeh/models/renderers.py#L116-L128
self.data_source.column_names
is not automatically updated whendata
changes.