aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/ipython/py2/IPython/kernel/__init__.py
diff options
context:
space:
mode:
authorMikhail Borisov <borisov.mikhail@gmail.com>2022-02-10 16:45:40 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:45:40 +0300
commit5d50718e66d9c037dc587a0211110b7d25a66185 (patch)
treee98df59de24d2ef7c77baed9f41e4875a2fef972 /contrib/python/ipython/py2/IPython/kernel/__init__.py
parenta6a92afe03e02795227d2641b49819b687f088f8 (diff)
downloadydb-5d50718e66d9c037dc587a0211110b7d25a66185.tar.gz
Restoring authorship annotation for Mikhail Borisov <borisov.mikhail@gmail.com>. Commit 2 of 2.
Diffstat (limited to 'contrib/python/ipython/py2/IPython/kernel/__init__.py')
-rw-r--r--contrib/python/ipython/py2/IPython/kernel/__init__.py68
1 files changed, 34 insertions, 34 deletions
diff --git a/contrib/python/ipython/py2/IPython/kernel/__init__.py b/contrib/python/ipython/py2/IPython/kernel/__init__.py
index 036548fffa..70a05ed4aa 100644
--- a/contrib/python/ipython/py2/IPython/kernel/__init__.py
+++ b/contrib/python/ipython/py2/IPython/kernel/__init__.py
@@ -1,35 +1,35 @@
-"""
-Shim to maintain backwards compatibility with old IPython.kernel imports.
-"""
-# Copyright (c) IPython Development Team.
-# Distributed under the terms of the Modified BSD License.
-
-import sys
-from warnings import warn
-
-from IPython.utils.shimmodule import ShimModule, ShimWarning
-
+"""
+Shim to maintain backwards compatibility with old IPython.kernel imports.
+"""
+# Copyright (c) IPython Development Team.
+# Distributed under the terms of the Modified BSD License.
+
+import sys
+from warnings import warn
+
+from IPython.utils.shimmodule import ShimModule, ShimWarning
+
warn("The `IPython.kernel` package has been deprecated since IPython 4.0."
- "You should import from ipykernel or jupyter_client instead.", ShimWarning)
-
-
-# zmq subdir is gone
-sys.modules['IPython.kernel.zmq.session'] = ShimModule(
- src='IPython.kernel.zmq.session', mirror='jupyter_client.session')
-sys.modules['IPython.kernel.zmq'] = ShimModule(
- src='IPython.kernel.zmq', mirror='ipykernel')
-
-for pkg in ('comm', 'inprocess'):
- src = 'IPython.kernel.%s' % pkg
- sys.modules[src] = ShimModule(src=src, mirror='ipykernel.%s' % pkg)
-
-for pkg in ('ioloop', 'blocking'):
- src = 'IPython.kernel.%s' % pkg
- sys.modules[src] = ShimModule(src=src, mirror='jupyter_client.%s' % pkg)
-
-# required for `from IPython.kernel import PKG`
-from ipykernel import comm, inprocess
-from jupyter_client import ioloop, blocking
-# public API
-from ipykernel.connect import *
-from jupyter_client import *
+ "You should import from ipykernel or jupyter_client instead.", ShimWarning)
+
+
+# zmq subdir is gone
+sys.modules['IPython.kernel.zmq.session'] = ShimModule(
+ src='IPython.kernel.zmq.session', mirror='jupyter_client.session')
+sys.modules['IPython.kernel.zmq'] = ShimModule(
+ src='IPython.kernel.zmq', mirror='ipykernel')
+
+for pkg in ('comm', 'inprocess'):
+ src = 'IPython.kernel.%s' % pkg
+ sys.modules[src] = ShimModule(src=src, mirror='ipykernel.%s' % pkg)
+
+for pkg in ('ioloop', 'blocking'):
+ src = 'IPython.kernel.%s' % pkg
+ sys.modules[src] = ShimModule(src=src, mirror='jupyter_client.%s' % pkg)
+
+# required for `from IPython.kernel import PKG`
+from ipykernel import comm, inprocess
+from jupyter_client import ioloop, blocking
+# public API
+from ipykernel.connect import *
+from jupyter_client import *