##// END OF EJS Templates
remove InlineBackend.quality from whatsnew
MinRK -
Show More
@@ -1,285 +1,283 b''
1 1 =====================
2 2 Development version
3 3 =====================
4 4
5 5 This document describes in-flight development work.
6 6
7 7 .. warning::
8 8
9 9 Please do not edit this file by hand (doing so will likely cause merge
10 10 conflicts for other Pull Requests). Instead, create a new file in the
11 11 `docs/source/whatsnew/pr` folder
12 12
13 13 Select Notebook Name When Renaming a Notebook
14 14 ---------------------------------------------
15 15
16 16 The default notebook name is Untitled. It's unlikely you want to keep this name
17 17 or part of it when naming your notebook. Instead, IPython will select the text
18 18 in the input field so the user can easily type over the name and change it.
19 19
20 20 clear_output changes
21 21 --------------------
22 22
23 23 * There is no longer a 500ms delay when calling ``clear_output``.
24 24 * The ability to clear stderr and stdout individually was removed.
25 25 * A new ``wait`` flag that prevents ``clear_output`` from being executed until new
26 26 output is available. This eliminates animation flickering by allowing the
27 27 user to double buffer the output.
28 28 * The output div height is remembered when the ``wait=True`` flag is used.
29 29
30 30 Extending Configurable Containers
31 31 ---------------------------------
32 32
33 33 Some configurable traits are containers (list, dict, set)
34 34 Config objects now support calling ``extend``, ``update``, ``insert``, etc.
35 35 on traits in config files, which will ultimately result in calling
36 36 those methods on the original object.
37 37
38 38 The effect being that you can now add to containers without having to copy/paste
39 39 the initial value::
40 40
41 41 c = get_config()
42 42 c.InlineBackend.rc.update({ 'figure.figsize' : (6, 4) })
43 43
44 44 Single codebase Python 3 support
45 45 --------------------------------
46 46
47 47 IPython previously supported Python 3 by running 2to3 during setup. We
48 48 have now switched to a single codebase which runs natively on Python 2.7
49 49 and 3.3.
50 50
51 51 For notes on how to maintain this, see :doc:`/development/pycompat`.
52 52
53 53 changes to hidden namespace on startup
54 54 --------------------------------------
55 55
56 56 Previously, all names declared in code run at startup
57 57 (startup files, ``ipython -i script.py``, etc.)
58 58 were added to the hidden namespace, which hides the names from tools like ``%whos``.
59 59 There are two changes to this behavior:
60 60
61 61 1. Scripts run on the command-line ``ipython -i script.py``now behave the same as if they were
62 62 passed to ``%run``, so their variables are never hidden.
63 63 2. A boolean config flag ``InteractiveShellApp.hide_initial_ns`` has been added to optionally
64 64 disable the hidden behavior altogether. The default behavior is unchanged.
65 65
66 66 Using dill to expand serialization support
67 67 ------------------------------------------
68 68
69 69 adds :func:`~IPython.utils.pickleutil.use_dill` for allowing
70 70 dill to extend serialization support in :mod:`IPython.parallel` (closures, etc.).
71 71 Also adds :meth:`DirectView.use_dill` convenience method for enabling dill
72 72 locally and on all engines with one call.
73 73
74 74 New IPython Console Lexer
75 75 -------------------------
76 76
77 77 The IPython console lexer has been rewritten and now supports tracebacks
78 78 and customized input/output prompts. An entire suite of lexers is now
79 79 available at :mod:`IPython.nbconvert.utils.lexers`. These include:
80 80
81 81 IPythonLexer & IPython3Lexer
82 82 Lexers for pure IPython (python + magic/shell commands)
83 83
84 84 IPythonPartialTracebackLexer & IPythonTracebackLexer
85 85 Supports 2.x and 3.x via the keyword `python3`. The partial traceback
86 86 lexer reads everything but the Python code appearing in a traceback.
87 87 The full lexer combines the partial lexer with an IPython lexer.
88 88
89 89 IPythonConsoleLexer
90 90 A lexer for IPython console sessions, with support for tracebacks.
91 91 Supports 2.x and 3.x via the keyword `python3`.
92 92
93 93 IPyLexer
94 94 A friendly lexer which examines the first line of text and from it,
95 95 decides whether to use an IPython lexer or an IPython console lexer.
96 96 Supports 2.x and 3.x via the keyword `python3`.
97 97
98 98 Previously, the :class:`IPythonConsoleLexer` class was available at
99 99 :mod:`IPython.sphinxext.ipython_console_hightlight`. It was inserted
100 100 into Pygments' list of available lexers under the name `ipython`. It should
101 101 be mentioned that this name is inaccurate, since an IPython console session
102 102 is not the same as IPython code (which itself is a superset of the Python
103 103 language).
104 104
105 105 Now, the Sphinx extension inserts two console lexers into Pygments' list of
106 106 available lexers. Both are IPyLexer instances under the names: `ipython` and
107 107 `ipython3`. Although the names can be confusing (as mentioned above), their
108 108 continued use is, in part, to maintain backwards compatibility and to
109 109 aid typical usage. If a project needs to make Pygments aware of more than just
110 110 the IPyLexer class, then one should not make the IPyLexer class available under
111 111 the name `ipython` and use `ipy` or some other non-conflicting value.
112 112
113 113 Code blocks such as:
114 114
115 115 .. code-block:: rst
116 116
117 117 .. code-block:: ipython
118 118
119 119 In [1]: 2**2
120 120 Out[1]: 4
121 121
122 122 will continue to work as before, but now, they will also properly highlight
123 123 tracebacks. For pure IPython code, the same lexer will also work:
124 124
125 125 .. code-block:: rst
126 126
127 127 .. code-block:: ipython
128 128
129 129 x = ''.join(map(str, range(10)))
130 130 !echo $x
131 131
132 132 Since the first line of the block did not begin with a standard IPython console
133 133 prompt, the entire block is assumed to consist of IPython code instead.
134 134
135 135 DisplayFormatter changes
136 136 ------------------------
137 137
138 138 There was no official way to query or remove callbacks in the Formatter API.
139 139 To remedy this, the following methods are added to :class:`BaseFormatter`:
140 140
141 141 - ``lookup(instance)`` - return appropriate callback or a given object
142 142 - ``lookup_by_type(type_or_str)`` - return appropriate callback for a given type or ``'mod.name'`` type string
143 143 - ``pop(type_or_str)`` - remove a type (by type or string).
144 144 Pass a second argument to avoid KeyError (like dict).
145 145
146 146 All of the above methods raise a KeyError if no match is found.
147 147
148 148 And the following methods are changed:
149 149
150 150 - ``for_type(type_or_str)`` - behaves the same as before, only adding support for ``'mod.name'``
151 151 type strings in addition to plain types. This removes the need for ``for_type_by_name()``,
152 152 but it remains for backward compatibility.
153 153
154 154 Notebook Widgets
155 155 ----------------
156 156
157 157 Available in the new `IPython.html.widgets` namespace, widgets provide an easy
158 158 way for IPython notebook users to display GUI controls in the IPython notebook.
159 159 IPython comes with bundle of built-in widgets and also the ability for users
160 160 to define their own widgets. A widget is displayed in the front-end using
161 161 using a view. For example, a FloatRangeWidget can be displayed using a
162 162 FloatSliderView (which is the default if no view is specified when displaying
163 163 the widget). IPython also comes with a bundle of views and the ability for the
164 164 user to define custom views. One widget can be displayed multiple times, in on
165 165 or more cells, using one or more views. All views will automatically remain in
166 166 sync with the widget which is accessible in the back-end.
167 167
168 168 The widget layer provides an MVC-like architecture on top of the comm layer.
169 169 It's useful for widgets that can be expressed via a list of properties.
170 170 Widgets work by synchronizing IPython traitlet models in the back-end with
171 171 backbone models in the front-end. The widget layer automatically handles
172 172
173 173 * delta compression (only sending the state information that has changed)
174 174 * wiring the message callbacks to the correct cells automatically
175 175 * inter-view synchronization (handled by backbone)
176 176 * message throttling (to avoid flooding the kernel)
177 177 * parent/child relationships between views (which one can override to specify custom parent/child relationships)
178 178 * ability to manipulate the widget view's DOM from python using CSS, $().addClass, and $().removeClass methods
179 179
180 180 Signing Notebooks
181 181 -----------------
182 182
183 183 To prevent untrusted code from executing on users' behalf when notebooks open,
184 184 we have added a signature to the notebook, stored in metadata.
185 185
186 186 For more information, see :ref:`signing_notebooks`.
187 187
188 188 Other changes
189 189 -------------
190 190
191 191 * `%%capture` cell magic now captures the rich display output, not just
192 192 stdout/stderr
193 193
194 194 * In notebook, Showing tooltip on tab has been disables to avoid conflict with
195 195 completion, Shift-Tab could still be used to invoke tooltip when inside
196 196 function signature and/or on selection.
197 197
198 198 * ``object_info_request`` as been replaced by ``object_info`` for consistency in the javascript API.
199 199 ``object_info`` as a simpler interface to register callback that is incompatible with ``object_info_request``.
200 200
201 201 * Previous versions of IPython on Linux would use the XDG config directory,
202 202 creating :file:`~/.config/ipython` by default. We have decided to go
203 203 back to :file:`~/.ipython` for consistency among systems. IPython will
204 204 issue a warning if it finds the XDG location, and will move it to the new
205 205 location if there isn't already a directory there.
206 206
207 207 * Equations, images and tables are now centered in Markdown cells.
208 208 * Multiline equations are now centered in output areas; single line equations
209 209 remain left justified.
210 210
211 211 * IPython config objects can be loaded from and serialized to JSON.
212 212 JSON config file have the same base name as their ``.py`` counterpart,
213 213 and will be loaded with higher priority if found.
214 214
215 215 * bash completion updated with support for all ipython subcommands and flags, including nbconvert
216 216
217 217 * ``ipython history trim``: added ``--keep=<N>`` as an alias for the more verbose
218 218 ``--HistoryTrim.keep=<N>``
219 219 * new ``ipython history clear`` subcommand, which is the same as the newly supported
220 220 ``ipython history trim --keep=0``
221 221
222 222 * You can now run notebooks in an interactive session via ``%run notebook.ipynb``.
223 223
224 224 * Print preview is back in the notebook menus, along with options to
225 225 download the open notebook in various formats. This is powered by
226 226 nbconvert.
227 227
228 228 * :exc:`~IPython.nbconvert.utils.pandoc.PandocMissing` exceptions will be
229 229 raised if Pandoc is unavailable, and warnings will be printed if the version
230 230 found is too old. The recommended Pandoc version for use with nbconvert is
231 231 1.12.1.
232 232
233 233 * The InlineBackend.figure_format flag now supports JPEG output if PIL/Pillow is available.
234 * The new ``InlineBackend.quality`` flag is a Integer in the range [10, 100] which controls
235 the quality of figures where higher values give nicer images (currently JPEG only).
236 234
237 235 * Input transformers (see :doc:`/config/inputtransforms`) may now raise
238 236 :exc:`SyntaxError` if they determine that input is invalid. The input
239 237 transformation machinery in IPython will handle displaying the exception to
240 238 the user and resetting state.
241 239
242 240 .. DO NOT EDIT THIS LINE BEFORE RELEASE. FEATURE INSERTION POINT.
243 241
244 242 Backwards incompatible changes
245 243 ------------------------------
246 244
247 245 * Python 2.6 and 3.2 are no longer supported: the minimum required
248 246 Python versions are now 2.7 and 3.3.
249 247 * The Transformer classes have been renamed to Preprocessor in nbconvert and
250 248 their `call` methods for them have been renamed to `preprocess`.
251 249 * The `call` methods of nbconvert post-processsors have been renamed to
252 250 `postprocess`.
253 251
254 252 * The module ``IPython.core.fakemodule`` has been removed.
255 253
256 254 * The alias system has been reimplemented to use magic functions. There should be little
257 255 visible difference while automagics are enabled, as they are by default, but parts of the
258 256 :class:`~IPython.core.alias.AliasManager` API have been removed.
259 257
260 258 * We fixed an issue with switching between matplotlib inline and GUI backends,
261 259 but the fix requires matplotlib 1.1 or newer. So from now on, we consider
262 260 matplotlib 1.1 to be the minimally supported version for IPython. Older
263 261 versions for the most part will work, but we make no guarantees about it.
264 262
265 263 * The :command:`pycolor` command has been removed. We recommend the much more capable
266 264 :command:`pygmentize` command from the `Pygments <http://pygments.org/>`_ project.
267 265 If you need to keep the exact output of :command:`pycolor`, you can still use
268 266 ``python -m IPython.utils.PyColorize foo.py``.
269 267
270 268 * :mod:`IPython.lib.irunner` and its command-line entry point have been removed.
271 269 It had fallen out of use long ago.
272 270
273 271 * The ``input_prefilter`` hook has been removed, as it was never
274 272 actually used by the code. The input transformer system offers much
275 273 more powerful APIs to work with input code. See
276 274 :doc:`/config/inputtransforms` for details.
277 275
278 276 * :class:`IPython.core.inputsplitter.IPythonInputSplitter` no longer has a method
279 277 ``source_raw_reset()``, but gains :meth:`~IPython.core.inputsplitter.IPythonInputSplitter.raw_reset`
280 278 instead. Use of ``source_raw_reset`` can be replaced with::
281 279
282 280 raw = isp.source_raw
283 281 transformed = isp.source_reset()
284 282
285 283 .. DO NOT EDIT THIS LINE BEFORE RELEASE. INCOMPAT INSERTION POINT.
General Comments 0
You need to be logged in to leave comments. Login now