-
Notifications
You must be signed in to change notification settings - Fork 226
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
Blank figures in Jupyter notebook #556
Comments
Thanks for opening an issue.
So it looks like ipympl was properly installed and is working with Notebook 7, otherwise you wouldn't see the figure controls. It's weird though that you are getting a white area. I will try to reproduce. |
Thanks, I updated my initial post with the list of extensions. As far as I can see, the versions should be compatible according to the version compatibility table. |
Yes, your installation looks perfectly fine. What is your matplotlib version? |
My matplotlib version is 3.9.0. |
Thanks, I can reproduce your issue.
|
Hm, I shut down and close the notebook, then reopen it, I can see the figure. |
It seems we have some kind of race condition in the initialization of the plot in the case of Notebook 7. It was never reported in the case of JupyterLab AFAIK. |
Sorry all, i've been off github and literally in the lab basement getting the final datasets I need in order finsih grad school. Unfortunately I've been unable to replicate this with jupyterlab 4.2.3 (or the |
Hi!
I downgraded to jupyterlab 4.2.3 to see if that helped based on @ianhi's comment, but it's still present. |
It seems to me that it's random, some kind of race condition. I wonder if simulating a slow connection using the dev tools would help us replicate the issue more easily. |
For what it's worth - it does not seem random on my machine. It reproduces reliably in Firefox, both with a local and remote jupyterlab environment. As in, I haven't yet seen it not reproduce! |
I have happily used interactive plots in jupyter notebooks for years with
%matplotlib notebook
. Unfortunately, since version 7 was introduced, I have experienced troubles with getting interactive plotting to work properly. I read that version 7 requires installing ipympl and%matplotlib ipympl
.Today, I set up a fresh virtual environment and installed jupyter and ipympl. Figures are opening, the controls appear, a figure title appears, but the figure contains no content. There is also no error message on the browser's developer console.
Steps to reproduce:
Then I use the code from the basic example
A white area is opening, the controls appear, but there is no figure content.
I have seen several similar issues on Stackoverflow, where the solution is usually to upgrade or downgrade one of the packages. However, these answers have aged as newer versions came out in the meantime. Is there a general recipe to identify the issue when interactive plotting fails?
Versions
The text was updated successfully, but these errors were encountered: