-
Notifications
You must be signed in to change notification settings - Fork 231
Closed
Description
Describe the issue
Ipympl (which is awesome) regularly breaks with minor matplotlib version updates. This typically causes a cryptic 'javascript error' in the jupyter notebook. Here is the output from the latest ipympl 0.9.5 and matplotlib 3.10, python 3.11. ubuntu 24.04
Failed to load model class 'MPLCanvasModel' from module 'jupyter-matplotlib'
loadClass@http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/446.bf169bd3821a9ba1aa62.js?v=bf169bd3821a9ba1aa62:1:75363
loadModelClass@http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/327.8166aeb81cf1531ca240.js?v=8166aeb81cf1531ca240:1:10579
_make_model@http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/327.8166aeb81cf1531ca240.js?v=8166aeb81cf1531ca240:1:7367
new_model@http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/327.8166aeb81cf1531ca240.js?v=8166aeb81cf1531ca240:1:5136
handle_comm_open@http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/327.8166aeb81cf1531ca240.js?v=8166aeb81cf1531ca240:1:3893
1446/v/this._handleCommOpen@http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/446.bf169bd3821a9ba1aa62.js?v=bf169bd3821a9ba1aa62:1:73900
_handleCommOpen@http://localhost:8888/static/lab/jlab_core.65f3a9357549aad3de7f.js?v=65f3a9357549aad3de7f:1:1399342
Downgrading to matplotlib 3.9 works as a workaround here.
However this issue reappears with seemingly every minor version update of matplotlib. Would it not be reasonable to pin matplotlib compatibility to the latest minor release that was tested? (e.g. for ipympl 0.9.5 to matplotlib >=3.5 <=3.9 instead of matplotlib <4) ?
Versions
3.11.0 | packaged by conda-forge | (main, Jan 14 2023, 12:27:40) [GCC 11.3.0]
ipympl version: 0.9.5
Selected Jupyter core packages...
IPython : 8.30.0
ipykernel : 6.29.5
ipywidgets : 8.1.5
jupyter_client : 8.6.3
jupyter_core : 5.7.2
jupyter_server : 2.14.2
jupyterlab : 4.3.3
nbclient : 0.10.1
nbconvert : 7.16.4
nbformat : 5.10.4
notebook : not installed
qtconsole : not installed
traitlets : 5.14.3
Known nbextensions:
config dir: /etc/jupyter/nbconfig
notebook section
jupyter-js-widgets/extension enabled
- Validating: problems found:
- require? X jupyter-js-widgets/extension
JupyterLab v4.3.3
/ssd/opt/miniforge3/envs/echopype/share/jupyter/labextensions
jupyter-matplotlib v0.11.5 enabled OK
jupyterlab_pygments v0.3.0 enabled OK (python, jupyterlab_pygments)
jupyterlab-execute-time v3.2.0 enabled OK (python, jupyterlab_execute_time)
@jupyter-widgets/jupyterlab-manager v5.0.13 enabled OK (python, jupyterlab_widgets)
@pyviz/jupyterlab_pyviz v3.0.3 enabled OK
@bokeh/jupyter_bokeh v4.0.5 enabled OK (python, jupyter_bokeh)
Metadata
Metadata
Assignees
Labels
No labels