You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for contacting us! Please read and follow these instructions carefully, then delete this introductory text to keep your issue easy to read. Note that the issue tracker is NOT the place for usage questions and technical assistance; post those at Discourse instead. Issues without the required information below may be closed immediately.
Description of expected behavior and the observed behavior
The code below runs as expected. When I replace FastListTemplate by FastGridTemplate, the function image is invoked twice per each tap. The output for 2 random taps looks like this:
FastListTemplate
=====1 212.17401500938087 40.78488372093024 Sun May 5 01:02:34 2024
=====2 212.17401500938087 40.78488372093024 Sun May 5 01:02:36 2024
=====1 225.90370018975332 30.416666666666664 Sun May 5 01:02:38 2024
=====2 225.90370018975332 30.416666666666664 Sun May 5 01:02:40 2024
FastGridTemplate
=====1 215.59535104364326 36.36904761904762 Sun May 5 01:01:48 2024
=====2 215.59535104364326 36.36904761904762 Sun May 5 01:01:50 2024
=====1 215.59535104364326 36.36904761904762 Sun May 5 01:01:51 2024
=====2 215.59535104364326 36.36904761904762 Sun May 5 01:01:53 2024
=====1 259.3429791271347 68.21428571428571 Sun May 5 01:01:58 2024
=====2 259.3429791271347 68.21428571428571 Sun May 5 01:02:00 2024
=====1 259.3429791271347 68.21428571428571 Sun May 5 01:02:00 2024
=====2 259.3429791271347 68.21428571428571 Sun May 5 01:02:02 2024
Complete, minimal, self-contained example code that reproduces the issue
# code goes here between backticks
import time
import panel as pn
import xarray as xr
import holoviews as hv
import hvplot.xarray
pn.extension()
ds = xr.tutorial.open_dataset('air_temperature')
_image = ds.hvplot('lon', 'lat')
stream = hv.streams.Tap(source=_image, x=-88 + 360, y=40)
def image(x, y):
print('=====1', x, y, time.ctime())
time.sleep(2)
print('=====2', x, y, time.ctime())
return _image * hv.Points([(x, y)], label='x: %0.3f, y: %0.3f' % (x, y)).opts(color='red', size=10)
item = pn.bind(image, stream.param.x, stream.param.y)
layout = pn.template.FastListTemplate(title='FastList', main=[item])
#layout = pn.template.FastGridTemplate(title='FastGrid')
#layout.main[0:6, 0:6] = item
layout.servable()
Thanks for contacting us! Please read and follow these instructions carefully, then delete this introductory text to keep your issue easy to read. Note that the issue tracker is NOT the place for usage questions and technical assistance; post those at Discourse instead. Issues without the required information below may be closed immediately.
ALL software version info
Description of expected behavior and the observed behavior
The code below runs as expected. When I replace
FastListTemplate
byFastGridTemplate
, the functionimage
is invoked twice per each tap. The output for 2 random taps looks like this:FastListTemplate
FastGridTemplate
Complete, minimal, self-contained example code that reproduces the issue
Stack traceback and/or browser JavaScript console output
Screenshots or screencasts of the bug in action
The text was updated successfully, but these errors were encountered: