From 702159755d89990092d0ae303d88ef4f164c4b33 2015-07-02 15:20:41 From: Matthias Bussonnier Date: 2015-07-02 15:20:41 Subject: [PATCH] Deprecate and undocument install_ext It seem to me that Python packaging has come up to a point where actually telling peoples they can install python extensions not using package manager is unreasonable. Recent extension even recommend using `install_ext` as **the way** to install things, which is unsecure, confusing, and there is no update mechanisme, nor version conflict resolution. --- diff --git a/IPython/core/magics/extension.py b/IPython/core/magics/extension.py index 7ef4695..2d6986d 100644 --- a/IPython/core/magics/extension.py +++ b/IPython/core/magics/extension.py @@ -19,6 +19,7 @@ import os # Our own packages from IPython.core.error import UsageError from IPython.core.magic import Magics, magics_class, line_magic +from warnings import warn #----------------------------------------------------------------------------- # Magic implementation classes @@ -42,6 +43,8 @@ class ExtensionMagics(Magics): -n filename : Specify a name for the file, rather than taking it from the URL. """ + warn("%install_ext` is deprecated, please distribute your extension(s)" + "as a python packages.", UserWarning) opts, args = self.parse_options(parameter_s, 'n:') try: filename = self.shell.extension_manager.install_extension(args, diff --git a/docs/source/config/extensions/index.rst b/docs/source/config/extensions/index.rst index 3ae10f1..73d8fb1 100644 --- a/docs/source/config/extensions/index.rst +++ b/docs/source/config/extensions/index.rst @@ -19,9 +19,6 @@ the `Framework :: IPython tag