positron
positron copied to clipboard
Support two-way communication in ipywidgets
Currently, if you create a widget with ipywidgets:
import ipywidgets as widgets
a = widgets.FloatSlider()
display(a)
And adjust the slider, the state is not updated in the kernel:
print(a.value)
# 0
Similarly, if you set the state in the kernel, the widget view doesn't update:
a.value = 100
# Nothing happens in the frontend
This is because we're not handling messages over the widget comm between its frontend and backend.