We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0702e32 commit a19816fCopy full SHA for a19816f
ipykernel/kernelbase.py
@@ -205,8 +205,6 @@ def __init__(self, **kwargs):
205
self.control_handlers[msg_type] = getattr(self, msg_type)
206
207
self.control_queue = Queue()
208
- if 'control_thread' in kwargs:
209
- kwargs['control_thread'].io_loop.add_callback(self.poll_control_queue)
210
211
@gen.coroutine
212
def dispatch_control(self, msg):
@@ -452,6 +450,13 @@ def start(self):
452
450
453
451
self.control_stream.on_recv(self.dispatch_control, copy=False)
454
+ if self.control_thread:
+ control_loop = self.control_thread.io_loop
455
+ else:
456
+ control_loop = self.io_loop
457
+
458
+ control_loop.add_callback(self.poll_control_queue)
459
460
self.shell_stream.on_recv(
461
partial(
462
self.schedule_dispatch,
0 commit comments