Connect to an existing kernel doesn't work

74 views
Skip to first unread message

Dave Hirschfeld

unread,
Aug 10, 2012, 5:52:39 AM8/10/12
to spyd...@googlegroups.com

When trying to connect to an existing kernel I get the following error in the Internal Console:

>>> Traceback (most recent call last):
  File "C:\dev\code\spyderlib\spyderlib\plugins\ipythonconsole.py", line 659, in new_client
    self.register_client(cf, kernel_widget_id, client_name)
  File "C:\dev\code\spyderlib\spyderlib\plugins\ipythonconsole.py", line 730, in register_client
    kernel = self.main.extconsole.shellwidgets[-1]
IndexError: list index out of range

No IPython console opens up after the error.

-Dave

Dave Hirschfeld

unread,
Aug 10, 2012, 6:00:18 AM8/10/12
to spyd...@googlegroups.com
If I already have another IPython Kernel/Console open I get a slightly different error in the internal console and a couple of message boxes. The console error is given below and the message box screen grabs are attached.

>>> Traceback (most recent call last):
  File "C:\dev\code\spyderlib\spyderlib\plugins\ipythonconsole.py", line 582, in refresh_plugin
Traceback (most recent call last):
  File "C:\dev\code\spyderlib\spyderlib\plugins\__init__.py", line 201, in visibility_changed
    self.refresh_plugin() #XXX Is it a good idea?
  File "C:\dev\code\spyderlib\spyderlib\plugins\ipythonconsole.py", line 582, in refresh_plugin
    self.main.extconsole.tabwidget.setCurrentIndex(idx)
TypeError: QTabWidget.setCurrentIndex(int): argument 1 has unexpected type 'NoneType'
    self.main.extconsole.tabwidget.setCurrentIndex(idx)
TypeError: QTabWidget.setCurrentIndex(int): argument 1 has unexpected type 'NoneType'
Traceback (most recent call last):
  File "C:\dev\code\spyderlib\spyderlib\plugins\__init__.py", line 201, in visibility_changed
Traceback (most recent call last):
  File "C:\dev\code\spyderlib\spyderlib\plugins\__init__.py", line 201, in visibility_changed
    self.refresh_plugin() #XXX Is it a good idea?
  File "C:\dev\code\spyderlib\spyderlib\plugins\ipythonconsole.py", line 582, in refresh_plugin
    self.main.extconsole.tabwidget.setCurrentIndex(idx)
TypeError: QTabWidget.setCurrentIndex(int): argument 1 has unexpected type 'NoneType'
    self.refresh_plugin() #XXX Is it a good idea?
  File "C:\dev\code\spyderlib\spyderlib\plugins\ipythonconsole.py", line 582, in refresh_plugin
    self.main.extconsole.tabwidget.setCurrentIndex(idx)
TypeError: QTabWidget.setCurrentIndex(int): argument 1 has unexpected type 'NoneType'

-Dave

 
MessageBox1.png
MessageBox2.png

Carlos Córdoba

unread,
Aug 14, 2012, 10:19:25 AM8/14/12
to spyd...@googlegroups.com
Hi Dave,

Thanks for the report. I can reproduce both errors. I'll fill an issue for them and try to solve it right away.

Cheers,
Carlos

El 10/08/12 05:00, Dave Hirschfeld escribió:
--
You received this message because you are subscribed to the Google Groups "spyder" group.
To view this discussion on the web visit https://groups.google.com/d/msg/spyderlib/-/VPRXg58eX8kJ.
To post to this group, send email to spyd...@googlegroups.com.
To unsubscribe from this group, send email to spyderlib+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/spyderlib?hl=en.

Carlos Córdoba

unread,
Aug 15, 2012, 11:53:33 AM8/15/12
to spyd...@googlegroups.com
Dave, I've added of couple of commits that should fix the problem. Could you test again with the latest tip and tell me if it's working for you?



El 10/08/12 05:00, Dave Hirschfeld escribió:
On Friday, August 10, 2012 10:52:39 AM UTC+1, Dave Hirschfeld wrote:

Dave Hirschfeld

unread,
Aug 16, 2012, 1:33:03 PM8/16/12
to spyder
Thanks Carlos, I can confirm that it's now working for me.

-Dave
Reply all
Reply to author
Forward
0 new messages