-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Notebook failed to load error #2747
Comments
Similar: #2733 |
I will investigate that "adapting to protocol 5.1" message... Was this notebook already open in your browser and you just refreshed after the upgrade? Perhaps some 5.0 JS was being loaded from cache? What browser are you using? Would you happen to have LastPass extension installed? |
I am running on Firefox 55 on macOS. Not using LastPass, but do have 1Password. If I use a different conda env with an older version of the notebook, the notebook runs fine. |
Ok, you're seeing the |
Hmmm... So when you close the notebook (I assume when you close the tab) and re-open, you don't get the error? |
Actually, it sometimes errors again, but in some cases the error goes away. Also, if I use Safari this does not seem to happen. I will try switching back to Safari as my regular browser and see if it ever comes up. |
I had the same error once, and only once, on 5.1.0rc1, on windows10/jupyter-5.1/chrome/very_slow_pc (zero plugins). Just restarting the kernel solved it. I would (blindly, as I'm not expert at all) bet on a slowness, or some remains of a previous widgets/whatever versions that are cleared with the relaunch. In the past, there were some bigger cash-clearance issues when we were upgrading, so it could be the same thing ? |
When you hit the error, is there any more detail in the browser's JS console? |
Those are just source maps so they shouldn't be causing any problems (although we should figure out how to avoid this error message)... |
I believe that the "Can't make callback..." error is coming from Mathjax, but I don't understand how - I don't think we have changed anything significant in our use of Mathjax, and I've never run into this error myself. You mentioned that it affects some notebooks but not others. Are there any of those notebooks which you could share? |
It seems to happen somewhat randomly. I can almost never reproduce it with a particular notebook, but it does keep occurring from time to time. And again, closing and reopening the tab makes the problem temporarily go away. Next time it happens I can post the notebook though. |
OK, just occurred with this notebook. |
I couldn't reproduce it in a clean conda env with notebook 5.1rc1 installed. 😕 If it's related to Mathjax, and it only affects some notebooks, I would have expected it to affect notebooks with maths expressions in to be rendered. As far as I can see, that notebook doesn't, which is puzzling. Is it possible that it only affects notebooks with no maths expressions for Mathjax to act on? |
Looking at the code, I also don't follow how it can give that error dialog without also logging to the console The only thing I can think of that might fit the symptoms is a JS caching issue. We've run before into caching issues which seem resilient to hard-refreshes and manually clearing the cache. I thought we had worked around the worst of them, but perhaps they're biting us again. The things we usually try in this case include:
@willingc also had the same symptoms which seemed to be related to a browser extension (Lastpass). You're not using the same browser or the same extension, but it could be that a different extension is having a similar effect. |
OK, thanks, Actually, I'm getting just as many occurrences in Safari as I did with Firefox now. I did try clearing the cache on FF, but that didnt help. I can try disabling 1Password and see if that fixes things. |
Can whoever is seeing this try using a private browsing mode/incognito mode, to make sure that there are no problems with extensions, cached data, cookies, etc? |
@jasongrout When I saw this in an earlier issue, the same behavior was seen in Safari's private mode too. Disabling LastPass worked for me on the notebooks that had the issue. Was the extension the root cause? I don't know. |
Grant just released a second release candidate. We don't think we've made any change that should fix it, but can anyone experiencing this upgrade and let us know whether it still occurs? |
Same issue on second release candidate. I've been trying to troubleshoot. This very old IPython/mathjax issue ipython/ipython#2349 seems closely related (same message being displayed "Type markdown..." and error message box). cc @gnestor @takluyver ipython/ipython#2349 (comment) |
Good find! It sounds like then it was due to caching issues and an outdated version of Mathjax. That was before we bundled Mathjax with the notebook. The "Type markdown and Latex" message is what an empty, rendered Markdown cell shows. It looks like it's adding that cell, but the error is stopping it before it sets its content. |
It does seem like a caching or browser issue. I experienced similar issue. Kernel message keeps flickering, "Adapting to protocol v5.1 for kernel eb3544e4..." message keeps showing. Switching from Chrome to IE solved it. Anaconda jupyter-notebook --version |
I agree with @fonnesbeck. I'm not convinced the browser change is a long term fix. |
@asears Are you running notebook 5.0.0 or 5.1.0rc*? If this is affecting 5.0.0 too, then we shouldn't hold off on releasing 5.1.0 on account of this issue (not to say that we shouldn't get to the bottom of this and resolve it). |
Sounds like a race condition, where what's in the browser's cache affects the order things happen. 😞 Agreed that if this is happening on 5.0 we should go ahead with the release, but for both @willingc and @fonnesbeck seemed to start seeing it on upgrade. It might be that changes in the upgrade make something which was previously rare more common. |
@takluyver I didn't see this behavior until the rc releases. |
I think I might have tracked this down - see #2792 . |
Nice work! I will test the PR to see if it does the trick. |
Can you open a new issue for debugging that? |
Actually, it appears that your branch this too. |
I take that back. It just occurred with your PR. I will start a new issue. |
I notice I have the same message when I open a notebook, not even starting to execute it, wait the kernel to say "ready", then trying as first action a "File->Make a Copy" (in Notebook-5.1rc2) applying #2792 (in " Lib\site-packages\notebook\static\base\js" ?) doesn't change anything. |
I've just released rc3, which includes a change to hopefully fix this error (I could never reproduce it, so it's hard to tell if it's fixed). Can you try upgrading and see if it works? |
@takluyver I haven't seen the error in a while since your last fix #2792. I briefly tested rc3 and it's looking fine for me. Will let you know if I see it in the future. |
@fonnesbeck Can you try installing rc3 and let us know if it resolves this issue: |
Yes, running it now. Will see what happens over the next few hours/days. |
No issues after a couple days of continuous use. Thanks! |
Thanks Chris! I will close this issue, then. We can reopen it if someone finds they can reproduce it. @gnestor I think this is the last issue tagged for 5.1. Is there anything else you're aware of that we should do before the release? |
Nope, just #2752 and it looks like that was just merged! 👍 |
It turns out that Jupyter have connection between kernels on different ports (not 8888), so when heavy firewall installed, it blocks such connections as suspected danger and kernels don't receive messages between each other and so Jupyter doesn't work. Short answer: change port from 8888 to 8889 |
Security software has been a recurring problem, unfortunately. No idea why 8888 vs 8889 makes a difference. |
The "adapting to protocol..." message is not an error. What is actually going wrong? |
So to clarify, the main issue is that I will try running cells in my notebook like @shigabeev above and they won't actually run. The star will be present but it's not running the cell or yielding an output. I've changed the port and am still encountering the issue. The only message I get is the one I posted earlier. |
Borrowing from the troubleshooting doc I'm adding in #3584: Jupyter doesn't load or doesn't work in the browser
|
After upgrading to the notebook from master ('5.1.0.dev'), I get a popup error saying that the notebook failed to load:
the underlying notebook is also truncated at the second cell, when in fact it is quite a large notebook.
If I close the notebook, and re-open it (without restarting it), it renders fine. The only thing unusual I notice in the console is:
The text was updated successfully, but these errors were encountered: