##// END OF EJS Templates
ConnectionFileMixin is a LoggingConfigurable
MinRK -
Show More
@@ -1,23 +1,12 b''
1 """Base class to manage the interaction with a running kernel
2 """
1 """Base class to manage the interaction with a running kernel"""
3 2
4 #-----------------------------------------------------------------------------
5 # Copyright (C) 2013 The IPython Development Team
6 #
7 # Distributed under the terms of the BSD License. The full license is in
8 # the file COPYING, distributed as part of this software.
9 #-----------------------------------------------------------------------------
10
11 #-----------------------------------------------------------------------------
12 # Imports
13 #-----------------------------------------------------------------------------
3 # Copyright (c) IPython Development Team.
4 # Distributed under the terms of the Modified BSD License.
14 5
15 6 from __future__ import absolute_import
16 7
17 8 import zmq
18 9
19 # Local imports
20 from IPython.config.configurable import LoggingConfigurable
21 10 from IPython.utils.traitlets import (
22 11 Any, Instance, Type,
23 12 )
@@ -31,11 +20,7 b' from .clientabc import KernelClientABC'
31 20 from .connect import ConnectionFileMixin
32 21
33 22
34 #-----------------------------------------------------------------------------
35 # Main kernel client class
36 #-----------------------------------------------------------------------------
37
38 class KernelClient(LoggingConfigurable, ConnectionFileMixin):
23 class KernelClient(ConnectionFileMixin):
39 24 """Communicates with a single kernel on any host via zmq channels.
40 25
41 26 There are four channels associated with each kernel:
@@ -27,7 +27,7 b' import zmq'
27 27 from IPython.external.ssh import tunnel
28 28
29 29 # IPython imports
30 from IPython.config import Configurable
30 from IPython.config import LoggingConfigurable
31 31 from IPython.core.profiledir import ProfileDir
32 32 from IPython.utils.localinterfaces import localhost
33 33 from IPython.utils.path import filefind, get_ipython_dir
@@ -381,7 +381,7 b' channel_socket_types = {'
381 381
382 382 port_names = [ "%s_port" % channel for channel in ('shell', 'stdin', 'iopub', 'hb', 'control')]
383 383
384 class ConnectionFileMixin(Configurable):
384 class ConnectionFileMixin(LoggingConfigurable):
385 385 """Mixin for configurable classes that work with connection files"""
386 386
387 387 # The addresses for the communication channels
@@ -5,7 +5,6 b''
5 5
6 6 from __future__ import absolute_import
7 7
8 # Standard library imports
9 8 import os
10 9 import re
11 10 import signal
@@ -15,8 +14,6 b' import warnings'
15 14
16 15 import zmq
17 16
18 # Local imports
19 from IPython.config.configurable import LoggingConfigurable
20 17 from IPython.utils.importstring import import_item
21 18 from IPython.utils.localinterfaces import is_local_ip, local_ips
22 19 from IPython.utils.path import get_ipython_dir
@@ -35,7 +32,7 b' from .managerabc import ('
35 32 )
36 33
37 34
38 class KernelManager(LoggingConfigurable, ConnectionFileMixin):
35 class KernelManager(ConnectionFileMixin):
39 36 """Manages a single kernel in a subprocess on this host.
40 37
41 38 This version starts kernels with Popen.
General Comments 0
You need to be logged in to leave comments. Login now