Skip to content

Commit

Permalink
Check for hv_created in tool tags
Browse files Browse the repository at this point in the history
  • Loading branch information
hoxbro committed Nov 21, 2024
1 parent f4dd02d commit e818c4d
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions holoviews/plotting/bokeh/raster.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class ServerHoverMixin:

def _update_hover(self, element):
tool = self.handles['hover']
if isinstance(tool.tooltips, Div):
if 'hv_created' in tool.tags and isinstance(tool.tooltips, Div):
self._hover_data = element.data
return
super()._update_hover(element)
Expand All @@ -40,7 +40,11 @@ def _init_tools(self, element, callbacks=None):
break

data = element.data
if hover is None or not (XArrayInterface.applies(data) and "selector_columns" in data.attrs):
if (
hover is None
or "hv_created" not in tool.tags
or not (XArrayInterface.applies(data) and "selector_columns" in data.attrs)
):
return tools

self._hover_data = data
Expand Down

0 comments on commit e818c4d

Please sign in to comment.