Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong widget protocol version thrown when using an ipywidget in a callback #100

Open
getehen opened this issue Jul 27, 2023 · 1 comment

Comments

@getehen
Copy link

getehen commented Jul 27, 2023

Hi,

I'm using panel and ipywidgets together, and whenever I do something related to ipywidgets from a callback function triggered by a panel widget, I've got this error : Wrong widget protocol version: received protocol version '', but was expecting major version '2' in the browser console

Expected behavior : No error

Simple program to reproduce :

import panel, ipywidgets

ipywidget = ipywidgets.Label(value="IPYWIDGET")
button = panel.widgets.Button(name='Actualiser')
test_box = ipywidgets.Box([])

def callback(value):
    something_happening_with_ipywidget = ipywidgets.Box([])

button.param.watch(callback, ['value'], onlychanged=True)

panel.Row(ipywidget, button).servable()

The error triggers only if I click the button, so it's not ipywidgets.Box([]) that's the cause of the error

I'm posting this here because it's thrown by ipywidgets_bokeh

PS : if I do not display any ipywidgets widget or if I don't do anything ipywidgets related in the callback, the error isn't thrown

@misolietavec
Copy link

misolietavec commented Jan 10, 2024

I have similar problem with panel and ipyleaflet, will create new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants