jupyter-widgets / ipywidgets

Interactive Widgets for the Jupyter Notebook
https://ipywidgets.readthedocs.io
BSD 3-Clause "New" or "Revised" License
3.14k stars 948 forks source link

Plot Issue: Failed to display Jupyter Widget of type FigureCanvasNbAgg #2105

Open rtadewald opened 6 years ago

rtadewald commented 6 years ago

I'm trying to create interactive plots. My JupyterLab server is running in the cloud, in a Google Compute Engine Instance.

When I try to plot some data, i got this: 41950377-4788a594-799c-11e8-8c7b-8bcf455490f4

jasongrout commented 6 years ago

Do you have the ipywidgets and matplotlib lab extensions installed?

jasongrout commented 6 years ago

Do jupyter labextension list at the command line to see the extensions you've installed.

rtadewald commented 6 years ago

Hello, Jason, Thanks for the help.

That's what I get:

rodrigo_tadewald@rtadewald-jupyterlab:~$ jupyter labextension list
JupyterLab v0.32.1
Known labextensions:
   app dir: /home/rodrigo_tadewald/anaconda3/share/jupyter/lab
@jupyter-widgets/jupyterlab-manager
        @jupyter-widgets/jupyterlab-manager v0.35.0  enabled  OK
@jupyterlab/plotly-extension
        @jupyterlab/plotly-extension v0.16.0  enabled  OK
jupyter-matplotlib
        jupyter-matplotlib v0.1.0  enabled  OK
jasongrout commented 6 years ago

And what version of ipywidgets do you have installed in the kernel? import ipywidgets; ipywidgets.__version__

rtadewald commented 6 years ago

My version is '7.1.1'.

jasongrout commented 6 years ago

Does it help to upgrade to ipywidgets 7.2? What version of ipympl do you have installed? Can you try in a fresh environment with a fresh install of ipympl? I think it has had some updates in the last few weeks.

amueller commented 5 years ago

Having the same issue with

JupyterLab v0.35.3
Known labextensions:
   app dir: /home/andy/anaconda3/envs/py37/share/jupyter/lab
        jupyter-matplotlib v0.3.0  enabled  OK

ipywidgets 7.4.2 ipympl 0.2.1

amueller commented 5 years ago

Solved, I had installed the pip way and needed to run

jupyter labextension install @jupyter-widgets/jupyterlab-manager
jupyter labextension install jupyter-matplotlib

It had prompted me if I want to install jupyter-matplotlib earlier and that ran some node installation but apparently I still needed to run these two lines.