Show More
@@ -57,7 +57,7 b' class BuiltinTrap(Configurable):' | |||
|
57 | 57 | from IPython.lib import deepreload |
|
58 | 58 | if self.shell.deep_reload: |
|
59 | 59 | from warnings import warn |
|
60 | warn("Automatically replacing builtin `reload` by `deepreload.reload` is deprecated, please import `reload` explicitly from `IPython.lib.deeprelaod", DeprecationWarning) | |
|
60 | warn("Automatically replacing builtin `reload` by `deepreload.reload` is deprecated and will be removed in IPython 6.0, please import `reload` explicitly from `IPython.lib.deeprelaod", DeprecationWarning) | |
|
61 | 61 | self.auto_builtins['reload'] = deepreload._dreload |
|
62 | 62 | else: |
|
63 | 63 | self.auto_builtins['dreload']= deepreload._dreload |
@@ -136,7 +136,7 b' class Deprec(object):' | |||
|
136 | 136 | |
|
137 | 137 | def __getattr__(self, name): |
|
138 | 138 | val = getattr(self.wrapped, name) |
|
139 | warnings.warn("Using ExceptionColors global is deprecated", DeprecationWarning) | |
|
139 | warnings.warn("Using ExceptionColors global is deprecated and will be removed in IPython 6.0", DeprecationWarning) | |
|
140 | 140 | # using getattr after warnings break ipydoctest in weird way for 3.5 |
|
141 | 141 | return val |
|
142 | 142 |
@@ -62,6 +62,8 b' class DisplayFormatter(Configurable):' | |||
|
62 | 62 | def _plain_text_only_changed(self, name, old, new): |
|
63 | 63 | warnings.warn("""DisplayFormatter.plain_text_only is deprecated. |
|
64 | 64 | |
|
65 | It will be removed in IPython 5.0 | |
|
66 | ||
|
65 | 67 | Use DisplayFormatter.active_types = ['text/plain'] |
|
66 | 68 | for the same effect. |
|
67 | 69 | """, DeprecationWarning) |
@@ -294,6 +294,8 b' class InteractiveShell(SingletonConfigurable):' | |||
|
294 | 294 | """ |
|
295 | 295 | **Deprecated** |
|
296 | 296 | |
|
297 | Will be removed in IPython 6.0 | |
|
298 | ||
|
297 | 299 | Enable deep (recursive) reloading by default. IPython can use the |
|
298 | 300 | deep_reload module which reloads changes in modules recursively (it |
|
299 | 301 | replaces the reload() function, so you don't need to change anything to |
@@ -365,13 +367,13 b' class InteractiveShell(SingletonConfigurable):' | |||
|
365 | 367 | # deprecated prompt traits: |
|
366 | 368 | |
|
367 | 369 | prompt_in1 = Unicode('In [\\#]: ', config=True, |
|
368 | help="Deprecated, use PromptManager.in_template") | |
|
370 | help="Deprecated, will be removed in IPython 5.0, use PromptManager.in_template") | |
|
369 | 371 | prompt_in2 = Unicode(' .\\D.: ', config=True, |
|
370 | help="Deprecated, use PromptManager.in2_template") | |
|
372 | help="Deprecated, will be removed in IPython 5.0, use PromptManager.in2_template") | |
|
371 | 373 | prompt_out = Unicode('Out[\\#]: ', config=True, |
|
372 | help="Deprecated, use PromptManager.out_template") | |
|
374 | help="Deprecated, will be removed in IPython 5.0, use PromptManager.out_template") | |
|
373 | 375 | prompts_pad_left = CBool(True, config=True, |
|
374 | help="Deprecated, use PromptManager.justify") | |
|
376 | help="Deprecated, will be removed in IPython 5.0, use PromptManager.justify") | |
|
375 | 377 | |
|
376 | 378 | def _prompt_trait_changed(self, name, old, new): |
|
377 | 379 | table = { |
@@ -433,6 +433,8 b' class MagicsManager(Configurable):' | |||
|
433 | 433 | def define_magic(self, name, func): |
|
434 | 434 | """[Deprecated] Expose own function as magic function for IPython. |
|
435 | 435 | |
|
436 | Will be removed in IPython 5.0 | |
|
437 | ||
|
436 | 438 | Example:: |
|
437 | 439 | |
|
438 | 440 | def foo_impl(self, parameter_s=''): |
@@ -15,6 +15,7 b' from __future__ import print_function' | |||
|
15 | 15 | |
|
16 | 16 | # Our own packages |
|
17 | 17 | from IPython.core.magic import Magics, magics_class, line_magic |
|
18 | import warnings | |
|
18 | 19 | |
|
19 | 20 | #----------------------------------------------------------------------------- |
|
20 | 21 | # Magic implementation classes |
@@ -28,7 +29,7 b' class DeprecatedMagics(Magics):' | |||
|
28 | 29 | def install_profiles(self, parameter_s=''): |
|
29 | 30 | """%install_profiles has been deprecated.""" |
|
30 | 31 | print('\n'.join([ |
|
31 | "%install_profiles has been deprecated.", | |
|
32 | "%install_profiles has been deprecated and will be removed in IPython 5.0.", | |
|
32 | 33 | "Use `ipython profile list` to view available profiles.", |
|
33 | 34 | "Requesting a profile with `ipython profile create <name>`", |
|
34 | 35 | "or `ipython --profile=<name>` will start with the bundled", |
@@ -37,7 +38,7 b' class DeprecatedMagics(Magics):' | |||
|
37 | 38 | |
|
38 | 39 | @line_magic |
|
39 | 40 | def install_default_config(self, parameter_s=''): |
|
40 | """%install_default_config has been deprecated.""" | |
|
41 | """%install_default_config has been deprecate and will be removed in IPython 5.0.""" | |
|
41 | 42 | print('\n'.join([ |
|
42 | 43 | "%install_default_config has been deprecated.", |
|
43 | 44 | "Use `ipython profile create <name>` to initialize a profile", |
@@ -71,7 +71,9 b" addflag('color-info', 'InteractiveShell.color_info'," | |||
|
71 | 71 | "Disable using colors for info related things." |
|
72 | 72 | ) |
|
73 | 73 | addflag('deep-reload', 'InteractiveShell.deep_reload', |
|
74 | """ **Deprecated** Enable deep (recursive) reloading by default. IPython can use the | |
|
74 | """ **Deprecated** and will be removed in IPython 5.0. | |
|
75 | ||
|
76 | Enable deep (recursive) reloading by default. IPython can use the | |
|
75 | 77 | deep_reload module which reloads changes in modules recursively (it |
|
76 | 78 | replaces the reload() function, so you don't need to change anything to |
|
77 | 79 | use it). deep_reload() forces a full reload of modules whose code may |
@@ -30,7 +30,6 b' from IPython.testing.decorators import (' | |||
|
30 | 30 | skipif, skip_win32, onlyif_unicode_paths, onlyif_cmds_exist, |
|
31 | 31 | ) |
|
32 | 32 | from IPython.testing import tools as tt |
|
33 | from IPython.utils import io | |
|
34 | 33 | from IPython.utils.process import find_cmd |
|
35 | 34 | from IPython.utils import py3compat |
|
36 | 35 | from IPython.utils.py3compat import unicode_type, PY3 |
@@ -351,7 +351,8 b' def _dreload(module, **kwargs):' | |||
|
351 | 351 | |
|
352 | 352 | """ |
|
353 | 353 | warn(""" |
|
354 |
injecting `dreload` in interactive namespace is deprecated, |
|
|
354 | injecting `dreload` in interactive namespace is deprecated, and will be removed in IPython 5.0. | |
|
355 | Please import `reload` explicitly from `IPython.lib.deepreload`. | |
|
355 | 356 | """, DeprecationWarning, stacklevel=2) |
|
356 | 357 | reload(module, **kwargs) |
|
357 | 358 |
@@ -4,7 +4,8 b' Moved to IPython.kernel.connect' | |||
|
4 | 4 | """ |
|
5 | 5 | |
|
6 | 6 | import warnings |
|
7 |
warnings.warn("IPython.lib.kernel moved to IPython.kernel.connect in IPython 1.0" |
|
|
7 | warnings.warn("IPython.lib.kernel moved to IPython.kernel.connect in IPython 1.0," | |
|
8 | "and will be removed in IPython 6.0.", | |
|
8 | 9 | DeprecationWarning |
|
9 | 10 | ) |
|
10 | 11 |
@@ -63,7 +63,7 b' class InteractiveShellEmbed(TerminalInteractiveShell):' | |||
|
63 | 63 | |
|
64 | 64 | if kw.get('user_global_ns', None) is not None: |
|
65 | 65 | warnings.warn("user_global_ns has been replaced by user_module. The\ |
|
66 | parameter will be ignored.", DeprecationWarning) | |
|
66 | parameter will be ignored, and removed in IPython 5.0", DeprecationWarning) | |
|
67 | 67 | |
|
68 | 68 | super(InteractiveShellEmbed,self).__init__(**kw) |
|
69 | 69 | |
@@ -158,7 +158,7 b' class InteractiveShellEmbed(TerminalInteractiveShell):' | |||
|
158 | 158 | """ |
|
159 | 159 | |
|
160 | 160 | if (global_ns is not None) and (module is None): |
|
161 | warnings.warn("global_ns is deprecated, use module instead.", DeprecationWarning) | |
|
161 | warnings.warn("global_ns is deprecated, and will be removed in IPython 5.0 use module instead.", DeprecationWarning) | |
|
162 | 162 | module = DummyMod() |
|
163 | 163 | module.__dict__ = global_ns |
|
164 | 164 |
@@ -200,22 +200,22 b' class TerminalIPythonApp(BaseIPythonApplication, InteractiveShellApp):' | |||
|
200 | 200 | |
|
201 | 201 | deprecated_subcommands = dict( |
|
202 | 202 | qtconsole=('qtconsole.qtconsoleapp.JupyterQtConsoleApp', |
|
203 | """DEPRECATD: Launch the Jupyter Qt Console.""" | |
|
203 | """DEPRECATED, Will be removed in IPython 6.0 : Launch the Jupyter Qt Console.""" | |
|
204 | 204 | ), |
|
205 | 205 | notebook=('notebook.notebookapp.NotebookApp', |
|
206 | """DEPRECATED: Launch the Jupyter HTML Notebook Server.""" | |
|
206 | """DEPRECATED, Will be removed in IPython 6.0 : Launch the Jupyter HTML Notebook Server.""" | |
|
207 | 207 | ), |
|
208 | 208 | console=('jupyter_console.app.ZMQTerminalIPythonApp', |
|
209 | """DEPRECATED: Launch the Jupyter terminal-based Console.""" | |
|
209 | """DEPRECATED, Will be removed in IPython 6.0 : Launch the Jupyter terminal-based Console.""" | |
|
210 | 210 | ), |
|
211 | 211 | nbconvert=('nbconvert.nbconvertapp.NbConvertApp', |
|
212 | "DEPRECATED: Convert notebooks to/from other formats." | |
|
212 | "DEPRECATED, Will be removed in IPython 6.0 : Convert notebooks to/from other formats." | |
|
213 | 213 | ), |
|
214 | 214 | trust=('nbformat.sign.TrustNotebookApp', |
|
215 | "DEPRECATED: Sign notebooks to trust their potentially unsafe contents at load." | |
|
215 | "DEPRECATED, Will be removed in IPython 6.0 : Sign notebooks to trust their potentially unsafe contents at load." | |
|
216 | 216 | ), |
|
217 | 217 | kernelspec=('jupyter_client.kernelspecapp.KernelSpecApp', |
|
218 | "DEPRECATED: Manage Jupyter kernel specifications." | |
|
218 | "DEPRECATED, Will be removed in IPython 6.0 : Manage Jupyter kernel specifications." | |
|
219 | 219 | ), |
|
220 | 220 | ) |
|
221 | 221 | subcommands = dict( |
@@ -234,7 +234,7 b' class TerminalIPythonApp(BaseIPythonApplication, InteractiveShellApp):' | |||
|
234 | 234 | ) |
|
235 | 235 | deprecated_subcommands['install-nbextension'] = ( |
|
236 | 236 | "notebook.nbextensions.InstallNBExtensionApp", |
|
237 | "DEPRECATED: Install Jupyter notebook extension files" | |
|
237 | "DEPRECATED, Will be removed in IPython 6.0 : Install Jupyter notebook extension files" | |
|
238 | 238 | ) |
|
239 | 239 | subcommands.update(deprecated_subcommands) |
|
240 | 240 |
@@ -76,7 +76,7 b' def apply_wrapper(wrapper,func):' | |||
|
76 | 76 | This will ensure that wrapped functions can still be well introspected via |
|
77 | 77 | IPython, for example. |
|
78 | 78 | """ |
|
79 |
warnings.warn("The function `apply_wrapper` is deprecated and might be removed in |
|
|
79 | warnings.warn("The function `apply_wrapper` is deprecated and might be removed in IPython 5.0", DeprecationWarning) | |
|
80 | 80 | |
|
81 | 81 | import nose.tools |
|
82 | 82 | |
@@ -128,7 +128,7 b' def make_label_dec(label,ds=None):' | |||
|
128 | 128 | True |
|
129 | 129 | """ |
|
130 | 130 | |
|
131 |
warnings.warn("The function `make_label_dec` is deprecated and might be removed in |
|
|
131 | warnings.warn("The function `make_label_dec` is deprecated and might be removed in IPython 5.0", DeprecationWarning) | |
|
132 | 132 | if isinstance(label, string_types): |
|
133 | 133 | labels = [label] |
|
134 | 134 | else: |
@@ -284,7 +284,7 b' def decorated_dummy(dec, name):' | |||
|
284 | 284 | import IPython.testing.decorators as dec |
|
285 | 285 | setup = dec.decorated_dummy(dec.skip_if_no_x11, __name__) |
|
286 | 286 | """ |
|
287 |
warnings.warn("The function `make_label_dec` is deprecated and might be removed in |
|
|
287 | warnings.warn("The function `make_label_dec` is deprecated and might be removed in IPython 5.0", DeprecationWarning) | |
|
288 | 288 | dummy = lambda: None |
|
289 | 289 | dummy.__name__ = name |
|
290 | 290 | return dec(dummy) |
@@ -317,7 +317,7 b' skip_if_no_x11 = skipif(_x11_skip_cond, _x11_skip_msg)' | |||
|
317 | 317 | |
|
318 | 318 | # not a decorator itself, returns a dummy function to be used as setup |
|
319 | 319 | def skip_file_no_x11(name): |
|
320 |
warnings.warn("The function `skip_file_no_x11` is deprecated and might be removed in |
|
|
320 | warnings.warn("The function `skip_file_no_x11` is deprecated and might be removed in IPython 5.0", DeprecationWarning) | |
|
321 | 321 | return decorated_dummy(skip_if_no_x11, name) if _x11_skip_cond else None |
|
322 | 322 | |
|
323 | 323 | # Other skip decorators |
@@ -371,7 +371,7 b' def onlyif_any_cmd_exists(*commands):' | |||
|
371 | 371 | """ |
|
372 | 372 | Decorator to skip test unless at least one of `commands` is found. |
|
373 | 373 | """ |
|
374 |
warnings.warn("The function `onlyif_any_cmd_exists` is deprecated and might be removed in |
|
|
374 | warnings.warn("The function `onlyif_any_cmd_exists` is deprecated and might be removed in IPython 5.0", DeprecationWarning) | |
|
375 | 375 | for cmd in commands: |
|
376 | 376 | if which(cmd): |
|
377 | 377 | return null_deco |
@@ -42,22 +42,6 b' from IPython.external.decorators import KnownFailure, knownfailureif' | |||
|
42 | 42 | |
|
43 | 43 | pjoin = path.join |
|
44 | 44 | |
|
45 | #----------------------------------------------------------------------------- | |
|
46 | # Warnings control | |
|
47 | #----------------------------------------------------------------------------- | |
|
48 | ||
|
49 | # Twisted generates annoying warnings with Python 2.6, as will do other code | |
|
50 | # that imports 'sets' as of today | |
|
51 | warnings.filterwarnings('ignore', 'the sets module is deprecated', | |
|
52 | DeprecationWarning ) | |
|
53 | ||
|
54 | # This one also comes from Twisted | |
|
55 | warnings.filterwarnings('ignore', 'the sha module is deprecated', | |
|
56 | DeprecationWarning) | |
|
57 | ||
|
58 | # Wx on Fedora11 spits these out | |
|
59 | warnings.filterwarnings('ignore', 'wxPython/wxWidgets release number mismatch', | |
|
60 | UserWarning) | |
|
61 | 45 | |
|
62 | 46 | # Enable printing all warnings raise by IPython's modules |
|
63 | 47 | warnings.filterwarnings('default', message='.*', category=Warning, module='IPy.*') |
General Comments 0
You need to be logged in to leave comments.
Login now