File tree Expand file tree Collapse file tree 1 file changed +0
-8
lines changed Expand file tree Collapse file tree 1 file changed +0
-8
lines changed Original file line number Diff line number Diff line change @@ -93,10 +93,7 @@ class KernelClient(ConnectionFileMixin):
93
93
# The PyZMQ Context to use for communication with the kernel.
94
94
context = Instance (zmq .asyncio .Context )
95
95
96
- _created_context : Bool = Bool (False )
97
-
98
96
def _context_default (self ) -> zmq .asyncio .Context :
99
- self ._created_context = True
100
97
return zmq .asyncio .Context ()
101
98
102
99
# The classes to use for the various channels
@@ -290,9 +287,6 @@ def start_channels(
290
287
:meth:`start_kernel`. If the channels have been stopped and you
291
288
call this, :class:`RuntimeError` will be raised.
292
289
"""
293
- # Create the context if needed.
294
- if not self ._created_context :
295
- self .context = self ._context_default ()
296
290
if iopub :
297
291
self .iopub_channel .start ()
298
292
if shell :
@@ -322,8 +316,6 @@ def stop_channels(self) -> None:
322
316
self .hb_channel .stop ()
323
317
if self .control_channel .is_alive ():
324
318
self .control_channel .stop ()
325
- if self ._created_context :
326
- self ._created_context = False
327
319
328
320
@property
329
321
def channels_running (self ) -> bool :
You can’t perform that action at this time.
0 commit comments