You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Still getting "Model not found" error instead of static figure when saving and re-opening the notebook #473
changed the title [-]Still getting "Model not found error instead of static figure when saving and re-opening the notebook[/-][+]Still getting "Model not found" error instead of static figure when saving and re-opening the notebook[/+]on Jun 29, 2022
Interesting! So something has changed between 3.0.0 and 3.0.18 that prevents it from displaying the image repr...
Another question: is it at all possible to obtain the same behaviour if the figure is placed inside another (e.g. VBox) widget?
This might be difficult, if the VBox cannot be displayed then we cannot do much about it. Also the VBox embeds the widget representation of the plot, not the image one.
I first run the notebook using 3.0.0, save it, re-open it and I still see the figure.
then I go back to a higher version of lab (3.0.18 or even 3.4)
open that same saved notebook, all of a sudden I can see the figure
I am guessing the png repr is correctly being saved by 3.0.0 (I don't know exactly which version broke between 3.0.0 and 3.0.18 yet), and then it can be loaded by later versions.
So this would mean that versions 3.0.18 and higher are failing to save the png rather than load it?
Can confirm that jupyterlab 3.0.0 does work and that jupyterlab 3.5.2 does not work. Also: the problem seems to be in saving the notebook. A simple notebook saved with 3.0.0 opens with a static image in 3.5.2.
I can confirm @davidfokkema. That 3.0.0 works and 3.5.2 not. Moreover in our case we use widgets with asynchronous calls. And this problem leads to widgets disappearing from the notebook approximately after one minute idle.
This is a bit old, but I just ran into this with a fresh installation of ipympl (0.9.4) & jupyter-lab (4.2.1).
However there is now a jupyter-lab menu Settings->Save Widget State Automatically which resolved this. Now the plots (the embedded png) are correctly displayed after re-opening a shutdown'd notebook. And it's also correctly displayed using nbsphinx as well.
Reacted by Marius Retegan, David Fokkema and Leah Teague
Activity
[-]Still getting "Model not found error instead of static figure when saving and re-opening the notebook[/-][+]Still getting "Model not found" error instead of static figure when saving and re-opening the notebook[/+]martinRenou commentedon Jun 29, 2022
Mmh I'm wondering if something has changed in JupyterLab recently that causes this. Would you be able to try to downgrade JupyterLab?
nvaytet commentedon Jun 29, 2022
Which version should I try?
martinRenou commentedon Jun 29, 2022
Sorry I didn't mean to close this issue 😕 maybe 3.0?
martinRenou commentedon Jun 29, 2022
Looks like I'm not the only one closing issues unintentionally https://twitter.com/choldgraf/status/1542169522282860550?s=20&t=7WHeO5lmM8dD62HwB5qHsg
nvaytet commentedon Jun 30, 2022
I am still getting the "Model not found" error in
Jupyterlab=3.0.18nvaytet commentedon Jun 30, 2022
Ah, version
3.0.0works!nvaytet commentedon Jun 30, 2022
Another question: is it at all possible to obtain the same behaviour if the figure is placed inside another (e.g.
VBox) widget?Thanks!
martinRenou commentedon Jun 30, 2022
Interesting! So something has changed between 3.0.0 and 3.0.18 that prevents it from displaying the image repr...
This might be difficult, if the VBox cannot be displayed then we cannot do much about it. Also the VBox embeds the widget representation of the plot, not the image one.
nvaytet commentedon Jun 30, 2022
What's interesting is:
I am guessing the png repr is correctly being saved by 3.0.0 (I don't know exactly which version broke between 3.0.0 and 3.0.18 yet), and then it can be loaded by later versions.
So this would mean that versions 3.0.18 and higher are failing to save the png rather than load it?
jklymak commentedon Jul 7, 2022
I can confirm that downgrading (
mamba install jupyterlab=3.0.0) also fixes this issue for me.davidfokkema commentedon Jan 9, 2023
Can confirm that jupyterlab 3.0.0 does work and that jupyterlab 3.5.2 does not work. Also: the problem seems to be in saving the notebook. A simple notebook saved with 3.0.0 opens with a static image in 3.5.2.
petrovfedor commentedon Jan 13, 2023
I can confirm @davidfokkema. That 3.0.0 works and 3.5.2 not. Moreover in our case we use widgets with asynchronous calls. And this problem leads to widgets disappearing from the notebook approximately after one minute idle.
petrovfedor commentedon Jan 13, 2023
Just tested this with 3.5.0 and it works.
jklymak commentedon Mar 2, 2023
I get "Error displaying widget: model not found" with the following env (and jupyterlab 3.6.1):
jupyterlab 3.0.0 works though.
lrlunin commentedon Jun 15, 2023
Not working in the jupyterlab 3.6.4 either.
vincefn commentedon May 25, 2024
This is a bit old, but I just ran into this with a fresh installation of ipympl (0.9.4) & jupyter-lab (4.2.1).
However there is now a jupyter-lab menu
Settings->Save Widget State Automaticallywhich resolved this. Now the plots (the embedded png) are correctly displayed after re-opening a shutdown'd notebook. And it's also correctly displayed usingnbsphinxas well.