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

Panel Leafmap: Error: Could not process update msg for model id #752

Open
MarcSkovMadsen opened this issue Jun 12, 2024 · 2 comments
Open
Labels
bug Something isn't working

Comments

@MarcSkovMadsen
Copy link

I'm trying to get leafmap working with Panel similarly to Solara-Leafmap.

A lot of features work. But when I click the tool icon nothing visible happens. But in the console the error below is logged.

Error: Could not process update msg for model id: d5ea3f69eff947928f88b58f36d3ceaa
    at ipywidgets_bokeh.js?v=562368b20a64be95651bb8246b7420f7fce55538dff999aefaa78662a14d0d39:8:1474147
    at async _._handleCommMsg (ipywidgets_bokeh.js?v=562368b20a64be95651bb8246b7420f7fce55538dff999aefaa78662a14d0d39:2:623644)
    at async _._handleMessage (ipywidgets_bokeh.js?v=562368b20a64be95651bb8246b7420f7fce55538dff999aefaa78662a14d0d39:2:625144)

image

import leafmap

import panel as pn

pn.extension("ipywidgets")

widget = leafmap.Map()

layout = pn.Column(
    widget,
).servable()

You can see how it should work here

image

I don't know if this issue is caused by ipywidgets_bokeh or by leafmap. Thus I have crossposted in ipywidgets_bokeh #106

Name: bokeh
Version: 3.4.1
Location: /home/jovyan/repos/private/panel/.venv/lib/python3.11/site-packages
Requires: contourpy, jinja2, numpy, packaging, pandas, pillow, pyyaml, tornado, xyzservices
Required-by: ipywidgets-bokeh, panel
---
Name: ipywidgets-bokeh
Version: 1.6.0
Location: /home/jovyan/repos/private/panel/.venv/lib/python3.11/site-packages
Requires: bokeh, ipykernel, ipywidgets
Required-by:
---
Name: leafmap
Version: 0.33.0
Location: /home/jovyan/repos/private/panel/.venv/lib/python3.11/site-packages
Requires: bqplot, colour, duckdb, folium, gdown, geojson, ipyevents, ipyfilechooser, ipyleaflet, ipywidgets, matplotlib, numpy, pandas, plotly, pyshp, pystac-client, python-box, scooby, whiteboxgui, xyzservices
Required-by:
---
Name: panel
Version: 1.5.0a3.post1.dev124+g5b59d248.d20240606
Location: /home/jovyan/repos/private/panel/.venv/lib/python3.11/site-packages
Editable project location: /home/jovyan/repos/private/panel
Requires: bleach, bokeh, linkify-it-py, markdown, markdown-it-py, mdit-py-plugins, packaging, pandas, param, pyviz-comms, requests, tqdm, typing-extensions
Required-by:
@giswqs
Copy link
Member

giswqs commented Jun 13, 2024

This seems an issue with ipywidgets_bokeh. Can you try using ipywidgets_bokeh directly with Panel without leafmap? If it doesn't work either, then it is an ipywidgets_bokeh issue. Otherwise, it may be a leafmap issue.

@giswqs
Copy link
Member

giswqs commented Jun 16, 2024

This does not seem to be issue unique to leafmap. I tried ipyleaflet, it does not work either.

import ipyleaflet

import panel as pn

pn.extension("ipywidgets")

widget = ipyleaflet.Map()

layout = pn.Column(
    widget,
).servable()

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants