-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Spyderlib fails to start new IPython consoles, raises socket exception #1275
Comments
From jed.lud...@gmail.com on 2013-02-19T21:39:48Z The proposed workaround actually looks like the right way to handle the situation. Sylvain cited this example from PyPy: https://github.com/pypy/pypy/blob/master/lib-python/2.7/socket.py I did additional research and found this post: http://stackoverflow.com/questions/3016369/catching-blocking-sigint-during-system-call The man pages for accept(2) describe EINTR not so much as a failure but as the call simply being interrupted by the system: http://www.kernel.org/doc/man-pages/online/pages/man2/accept.2.html In that light, silently ignoring interrupted calls when inside infinite polling loops seems like the correct thing to do. |
From jed.lud...@gmail.com on 2013-02-19T22:04:52Z This issue was updated by revision 91edc30721d9 . I implemented Sylvain's patches with minor modfication. Only Errno 4 Status: Fixed |
From ebori...@gmail.com on 2013-02-20T06:07:30Z I would suggest using 'errno.EINTR' rather than '4'. |
From sylvain....@gmail.com on 2013-02-20T08:20:42Z If you have other interruptible system calls in Spyder, maybe it would be a good idea to do this all the time. |
From jed.lud...@gmail.com on 2013-02-20T09:13:34Z I agree, although I think we'll approach this cautiously. I'd prefer to allow them to show up on a case by case basis first. |
From jed.lud...@gmail.com on 2013-02-20T10:22:48Z This issue was updated by revision bf42a0cb285b . Now using errno constants instead of hard-coded integers. |
From steve.f....@gmail.com on 2013-02-20T11:15:11Z I'm not sure if this is related or not. I just installed ipython 0.3.1 in an attempt to use it. When I try to start it from the Interpreters menu the console just shows this: |
From jed.lud...@gmail.com on 2013-02-20T12:54:45Z @-Steve, does the IPython console eventually show up though? |
From steve.f....@gmail.com on 2013-02-20T16:09:42Z No, it never shows up. |
From jed.lud...@gmail.com on 2013-02-20T16:46:41Z @-Steve: It looks like the failure is more related to your sitecustomize file not being successfully imported. Do you have a customized flavor of that file, different from what ships with Spyder by default? |
From sylvain....@gmail.com on 2013-02-22T15:33:21Z Regarding Carlos's modification in revision 7a49c6a1cfb2 regarding the "while True:", there is another one in /spyderlib/widgets/externalshell/introspection.py |
From jed.lud...@gmail.com on 2013-02-26T07:29:38Z I'm not sure I understand why fractionally increasing the loop speed a the location that was modified in revision 7a49c6a1cfb2 is important. I acknowledge that there is a difference at least for Python 2.7 [1], but I just don't see why it matters. [1] http://stackoverflow.com/questions/3815359/while-1-vs-for-whiletrue-why-is-there-a-difference |
From ccordoba12 on 2013-02-26T08:26:09Z I think it could be useful for two reasons:
|
From jed.lud...@gmail.com on 2013-02-26T08:32:33Z @-Carlos: I have no problem with the change. Feel free to make the modification suggested by Sylvain in comment 11 if you'd like. |
From steve.f....@gmail.com on 2013-03-04T08:12:25Z I still can't get IPython to come up. |
From jed.lud...@gmail.com on 2013-03-05T00:32:28Z @-Steve: As mentioned in comment 10, it looks like sitecustomize.py is not loading. For reference, it's this file: https://code.google.com/p/spyderlib/source/browse/spyderlib/widgets/externalshell/sitecustomize.py Have you further customized sitecustomize.py? :) |
From jtaylor....@googlemail.com on 2013-03-15T14:45:05Z you need these temporary failure loops on all system calls dealing with slow devices, see man 7 signal |
From pierre.raybaut on 2013-03-17T07:03:03Z @Julian (comment |
From pierre.raybaut on 2013-03-17T07:04:34Z This issue was updated by revision ee7ac4c9439a . @-Steve: this is the changeset I was referring to in my previous comment. |
From ccordoba12 on 2013-04-06T20:28:43Z Labels: Cat-IPythonConsole |
From jed.lud...@gmail.com on 2013-02-20T00:33:30Z
Original report from Sylvain Corlay in this thread: https://groups.google.com/d/topic/spyderlib/NF7o04Q_41M/discussion reproduced here for simplicity. Sylvain later submitted the attached patches as workarounds.
Hi,
It seems that under Ubuntu 12.04 64 bits, spyder fails to open new IPython consoles. It does start a new kernel in the "Console" widget but no console is opened in the "IPython Console" widget. However, I can still use a "connect to an existing kernel" to connect to it. A traceback is produced in the internal console:
(When trying revisions older than revision 4a06c308b99d (Fixed crash at startup occuring when restoring Project Explorer's tree view), spyder crashes at startup. However I did not have this issue before. I can avoid this problem by deleting the configuration folder .spyder2 that does not seem to work with older versions. )
It is odd because I did not have this ipython console issue in the past with the corresponding revisions. Although there has been a few packages updated in the meanwhile.
Thanks,
S.
Attachment: introspection.diff spyder.diff
Original issue: http://code.google.com/p/spyderlib/issues/detail?id=1275
The text was updated successfully, but these errors were encountered: