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
Kernel Has Died error in Notebook #1198
Comments
The odds are that your kernel has not died, and the bug is false positive in the heartbeat code. Can you post: pyzmq version ( Can you describe what you are typically doing when this happens? Are you using pylab mode? |
zmq.__version__
Out[6]: '2.1.11'
zmq.zmq_version()
Out[7]: '2.1.11' Python version 2.7 on Windows XP 32 bit The most repeatable way it happens is when first loading a notebook from the dashboard...like 5 seconds after I see the cells load I get the dead kernel message. If I x out the window(choose nothing), I am not able to execute code. If I restart the kernel it works fine, and if I close the notebook and open it back up it does not happen again. Yes, I am using pylab mode in general, but this happens without it enabled as well. |
Okay, thanks. Try increasing the heartbeat period by setting |
On first test that seems to work, I'll play around with it some more tomorrow. This computer is a bit old/slow, is the kernel manager tripping because it is taking a while? |
Without injecting some debugging statements it's a bit hard to tell, but the way the heartbeat works in the notebook is this: The kernel manager sends a ping every so often (in this case every Looking at the code, I can see two problems:
I was able to replicate (as far as I can tell) your issue by cutting the heartbeat time down to 300 milliseconds, so my notebook keeps seeing dead kernels. But if I delay the first heartbeat for the original 3 seconds, I once again have a perfectly responsive kernel. So the solution here is that we need to allow user-configurable delay on the first beat, and it should probably start out around 5s, which should cover any normal environment. |
I added what should be a fix to my existing notebook PR #1187, if you want to try that out. |
I too see this occasionally but have no idea of what is causing it. Cheers, Brian On Thu, Dec 22, 2011 at 12:29 PM, anderwm
Brian E. Granger |
@ellisonbg - it's most likely that it's taking more than one heartbeat cycle for the kernel to start. See above comments and link for discussion and a proposed fix. |
This is probably not appropriate here, but I am new to Git. Is the best way to try your code: 1)make your fork a remote or is there a more effective mechanism, or hit me with a link to read |
Yes, that's exactly right. For more specific steps:
|
And just to make sure the comparison is apt, If I run
from any other directory it will be the original code...like from site_packages? or I should say, it will get the code from site_packages/ipython/whatever |
Yes, unless you have done a 'dev' install, either with |
So far I have not been able to recreate the error with the new code, so that's a good sign. I will continue to test it as I have time. |
closed by PR #1187 |
I get this message occasionally at seemingly random times during a notebook session. Although the kernel restarts fine, without a more interesting error message there is not a lot I can do. I am sure this was added to recover from errors without much effort from the end user, but is there somewhere I can look to see who is the serial killer that keeps murdering my beloved kernels?
The text was updated successfully, but these errors were encountered: