Open Michael-Barletta opened 1 year ago
A MRE here:
import hvplot.xarray # noqa
import panel as pn
import xarray as xr
def update_map(quadmesh):
if quadmesh:
return data.hvplot.quadmesh() # Wrapping this with `pn.panel` works
return data.isel(time=0).hvplot.quadmesh()
data = xr.tutorial.load_dataset("air_temperature")
checkbox = pn.widgets.Checkbox(value=True, name="show_quadmesh")
pn.Column(checkbox, pn.bind(update_map, checkbox)).servable()
https://github.com/holoviz/panel/assets/19758978/e513119a-7f6f-429c-8cc1-f8b4a5700fdc
ALL software version info
bokeh 3.1.1 holoviews 1.16.2 geoviews 1.10.0 panel 1.1.1 jupyterlab 4.0.2
Description of expected behavior and the observed behavior
When I use panel dropdowns to select variables and update a geoviews plot using example data, the time slider fails to pop up even though it is being specificized when creating the geoviews dataset. When I just plot the data without going through the steps of selecting variables from my panel app, the time slider works and is visible without issue.
Complete, minimal, self-contained example code that reproduces the issue
(https://github.com/Michael-Barletta/holoviz_examples/blob/main/time_slider_issue.ipynb)
@Hoxbro gave a workaround to wrap the output in pn.panel()