From e1b98ee4a9f1fbc48c6f711a56cda7e126cba92e 2015-05-28 19:08:56 From: Matthias Bussonnier Date: 2015-05-28 19:08:56 Subject: [PATCH] do not show pending deprecation warnign --- diff --git a/IPython/core/interactiveshell.py b/IPython/core/interactiveshell.py index a3092ae..3011ce8 100644 --- a/IPython/core/interactiveshell.py +++ b/IPython/core/interactiveshell.py @@ -667,14 +667,12 @@ class InteractiveShell(SingletonConfigurable): def init_deprecation_warnings(self): """ - register default filter for (pending) deprecation warning. + register default filter for deprecation warning. This will allow deprecation warning of function used interactively to show warning to users, and still hide deprecation warning from libraries import. """ warnings.filterwarnings("default", category=DeprecationWarning, module=self.user_ns.get("__name__")) - warnings.filterwarnings("default", category=PendingDeprecationWarning, module=self.user_ns.get("__name__")) - def init_builtins(self): # A single, static flag that we set to True. Its presence indicates diff --git a/docs/source/whatsnew/pr/deprecation_warning.rst b/docs/source/whatsnew/pr/deprecation_warning.rst index 4fc69e3..3ba538b 100644 --- a/docs/source/whatsnew/pr/deprecation_warning.rst +++ b/docs/source/whatsnew/pr/deprecation_warning.rst @@ -1,4 +1,4 @@ -Code raising ``DeprecationWarning`` or ``PendingDeprecationWarning`` that are +Code raising ``DeprecationWarning`` entered by the user in an interactive session will now display the warning by default. See :ghpull:`8480` an :ghissue:`8478`.