##// END OF EJS Templates
Backport PR #14174: Whats new 8.12.3 (#14179)
Matthias Bussonnier -
r28421:7e4826ab merge
parent child Browse files
Show More
@@ -1,1656 +1,1674 b''
1 1 ============
2 2 8.x Series
3 3 ============
4 4
5 .. _version 8.12.3:
6
7 IPython 8.12.3
8 --------------
9
10 Tiny release of 8.12.3 that backport a small number of fixes for users still
11 using Python 3.8.
12
13 - :ghpull:`14080` add passthrough filter shortcuts
14 - :ghpull:`14169` Fix `InteractiveShellEmbed`
15
16 .. _version 8.12.2:
17
18 IPython 8.12.2
19 --------------
20
21 See 8.13 Release notes.
22
5 23 .. _version 8.12.1:
6 24
7 25 IPython 8.12.1
8 26 --------------
9 27
10 28 This is the twin release of IPython 8.13 that contain only critical UI and bug
11 29 fixes. The next minor version of IPython has dropped support for Python 3.8 – as
12 30 per Nep 29 and this IPython 8.12.x will now only receive bugfixes.
13 31
14 32
15 33 - :ghpull:`14004` Fix a bug introduced in IPython 8.12 that crash when
16 34 inspecting some docstrings.
17 35 - :ghpull:`14010` Fix fast traceback code that was not working in some case.
18 36 - :ghpull:`14014` Fix ``%page`` magic broken in some case.
19 37 - :ghpull:`14026`, :ghpull:`14027` Tweak default shortcut with respect to
20 38 autosuggestions.
21 39 - :ghpull:`14033` add back the ability to use ``.get()`` on OInfo object for
22 40 backward compatibility with h5py (this will be re-deprecated later, and h5py
23 41 will also get a fix).
24 42
25 43 As usual you can find the full list of PRs on GitHub under `the 8.12.1 milestone
26 44 <https://github.com/ipython/ipython/milestone/116?closed=1>`__.
27 45
28 46 Thanks to the D.E. Shaw group for the request and sponsoring the work.
29 47
30 48 .. _version 8.12.0:
31 49
32 50 IPython 8.12
33 51 ------------
34 52
35 53 Hopefully slightly early release for IPython 8.12. Last Thursday of the month,
36 54 even if I guess it's likely already Friday somewhere in the pacific ocean.
37 55
38 56 A number of PRs and bug fixes this month with close to 20 PRs merged !
39 57
40 58
41 59 The IPython repo reached :ghpull:``14000`` !! Actually the PR that create those exact release
42 60 note is :ghpull:`14000`. Ok, more issues and PR is not always better, and I'd
43 61 love to have more time to close issues and Pull Requests.
44 62
45 63 Let's note that in less than 2 month JupyterCon is back, in Paris please visit
46 64 `jupytercon.com <https://jupytercon.com>`__, and looking forward to see you
47 65 there.
48 66
49 67
50 68
51 69 Packagers should take note that ``typing_extension`` is now a mandatory dependency
52 70 for Python versions ``<3.10``.
53 71
54 72
55 73
56 74 Let's note also that according to `NEP29
57 75 <https://numpy.org/neps/nep-0029-deprecation_policy.html>`__, It is soon time to
58 76 stop support for Python 3.8 that will be release more than 3 and 1/2 years ago::
59 77
60 78 On Apr 14, 2023 drop support for Python 3.8 (initially released on Oct 14, 2019)
61 79
62 80 Thus I am likely to stop advertising support for Python 3.8 in the next
63 81 release at the end of April.
64 82
65 83
66 84 Here are some miscellaneous updates of interest:
67 85
68 86 - :ghpull:`13957` brings updates to the Qt integration, particularly for Qt6.
69 87 - :ghpull:`13960` fixes the %debug magic command to give access to the local
70 88 scope.
71 89 - :ghpull:`13964` fixes some crashes with the new fast traceback code. Note that
72 90 there are still some issues with the fast traceback code, and I a, likely
73 91 to fix and tweak behavior.
74 92 - :ghpull:`13973` We are slowly migrating IPython internals to use proper type
75 93 objects/dataclasses instead of dictionaries to allow static typing checks.
76 94 These are technically public API and could lead to breakage, so please let us
77 95 know if that's the case and I'll mitigate.
78 96 - :ghpull:`13990`, :ghpull:`13991`, :ghpull:`13994` all improve keybinding and
79 97 shortcut configurability.
80 98
81 99 As usual you can find the full list of PRs on GitHub under `the 8.12 milestone
82 100 <https://github.com/ipython/ipython/milestone/114?closed=1>`__.
83 101
84 102 We want to thank the D.E. Shaw group for requesting and sponsoring the work on
85 103 the following big feature. We had productive discussions on how to best expose
86 104 this feature
87 105
88 106 Dynamic documentation dispatch
89 107 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
90 108
91 109 We are experimenting with dynamic documentation dispatch for object attribute.
92 110 See :ghissue:`13860`. The goal is to allow object to define documentation for
93 111 their attributes, properties, even when those are dynamically defined with
94 112 `__getattr__`.
95 113
96 114 In particular when those objects are base types it can be useful to show the
97 115 documentation
98 116
99 117
100 118 .. code-block:: ipython
101 119
102 120
103 121 In [1]: class User:
104 122 ...:
105 123 ...: __custom_documentations__ = {
106 124 ...: "first": "The first name of the user.",
107 125 ...: "last": "The last name of the user.",
108 126 ...: }
109 127 ...:
110 128 ...: first:str
111 129 ...: last:str
112 130 ...:
113 131 ...: def __init__(self, first, last):
114 132 ...: self.first = first
115 133 ...: self.last = last
116 134 ...:
117 135 ...: @property
118 136 ...: def full(self):
119 137 ...: """`self.first` and `self.last` joined by a space."""
120 138 ...: return self.first + " " + self.last
121 139 ...:
122 140 ...:
123 141 ...: user = Person('Jane', 'Doe')
124 142
125 143 In [2]: user.first?
126 144 Type: str
127 145 String form: Jane
128 146 Length: 4
129 147 Docstring: the first name of a the person object, a str
130 148 Class docstring:
131 149 ....
132 150
133 151 In [3]: user.last?
134 152 Type: str
135 153 String form: Doe
136 154 Length: 3
137 155 Docstring: the last name, also a str
138 156 ...
139 157
140 158
141 159 We can see here the symmetry with IPython looking for the docstring on the
142 160 properties:
143 161
144 162 .. code-block:: ipython
145 163
146 164
147 165 In [4]: user.full?
148 166 HERE
149 167 Type: property
150 168 String form: <property object at 0x102bb15d0>
151 169 Docstring: first and last join by a space
152 170
153 171
154 172 Note that while in the above example we use a static dictionary, libraries may
155 173 decide to use a custom object that define ``__getitem__``, we caution against
156 174 using objects that would trigger computation to show documentation, but it is
157 175 sometime preferable for highly dynamic code that for example export ans API as
158 176 object.
159 177
160 178
161 179
162 180 .. _version 8.11.0:
163 181
164 182 IPython 8.11
165 183 ------------
166 184
167 185 Back on almost regular monthly schedule for IPython with end-of-month
168 186 really-late-Friday release to make sure some bugs are properly fixed.
169 187 Small addition of with a few new features, bugfix and UX improvements.
170 188
171 189 This is a non-exhaustive list, but among other you will find:
172 190
173 191 Faster Traceback Highlighting
174 192 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
175 193
176 194 Resurrection of pre-IPython-8 traceback highlighting code.
177 195
178 196 Really long and complicated files were slow to highlight in traceback with
179 197 IPython 8 despite upstream improvement that make many case better. Therefore
180 198 starting with IPython 8.11 when one of the highlighted file is more than 10 000
181 199 line long by default, we'll fallback to a faster path that does not have all the
182 200 features of highlighting failing AST nodes.
183 201
184 202 This can be configures by setting the value of
185 203 ``IPython.code.ultratb.FAST_THRESHOLD`` to an arbitrary low or large value.
186 204
187 205
188 206 Autoreload verbosity
189 207 ~~~~~~~~~~~~~~~~~~~~
190 208
191 209 We introduce more descriptive names for the ``%autoreload`` parameter:
192 210
193 211 - ``%autoreload now`` (also ``%autoreload``) - perform autoreload immediately.
194 212 - ``%autoreload off`` (also ``%autoreload 0``) - turn off autoreload.
195 213 - ``%autoreload explicit`` (also ``%autoreload 1``) - turn on autoreload only for modules
196 214 whitelisted by ``%aimport`` statements.
197 215 - ``%autoreload all`` (also ``%autoreload 2``) - turn on autoreload for all modules except those
198 216 blacklisted by ``%aimport`` statements.
199 217 - ``%autoreload complete`` (also ``%autoreload 3``) - all the fatures of ``all`` but also adding new
200 218 objects from the imported modules (see
201 219 IPython/extensions/tests/test_autoreload.py::test_autoload_newly_added_objects).
202 220
203 221 The original designations (e.g. "2") still work, and these new ones are case-insensitive.
204 222
205 223 Additionally, the option ``--print`` or ``-p`` can be added to the line to print the names of
206 224 modules being reloaded. Similarly, ``--log`` or ``-l`` will output the names to the logger at INFO
207 225 level. Both can be used simultaneously.
208 226
209 227 The parsing logic for ``%aimport`` is now improved such that modules can be whitelisted and
210 228 blacklisted in the same line, e.g. it's now possible to call ``%aimport os, -math`` to include
211 229 ``os`` for ``%autoreload explicit`` and exclude ``math`` for modes ``all`` and ``complete``.
212 230
213 231 Terminal shortcuts customization
214 232 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
215 233
216 234 Previously modifying shortcuts was only possible by hooking into startup files
217 235 and practically limited to adding new shortcuts or removing all shortcuts bound
218 236 to a specific key. This release enables users to override existing terminal
219 237 shortcuts, disable them or add new keybindings.
220 238
221 239 For example, to set the :kbd:`right` to accept a single character of auto-suggestion
222 240 you could use::
223 241
224 242 my_shortcuts = [
225 243 {
226 244 "command": "IPython:auto_suggest.accept_character",
227 245 "new_keys": ["right"]
228 246 }
229 247 ]
230 248 %config TerminalInteractiveShell.shortcuts = my_shortcuts
231 249
232 250 You can learn more in :std:configtrait:`TerminalInteractiveShell.shortcuts`
233 251 configuration reference.
234 252
235 253 Miscellaneous
236 254 ~~~~~~~~~~~~~
237 255
238 256 - ``%gui`` should now support PySide6. :ghpull:`13864`
239 257 - Cli shortcuts can now be configured :ghpull:`13928`, see above.
240 258 (note that there might be an issue with prompt_toolkit 3.0.37 and shortcut configuration).
241 259
242 260 - Capture output should now respect ``;`` semicolon to suppress output.
243 261 :ghpull:`13940`
244 262 - Base64 encoded images (in jupyter frontend), will not have trailing newlines.
245 263 :ghpull:`13941`
246 264
247 265 As usual you can find the full list of PRs on GitHub under `the 8.11 milestone
248 266 <https://github.com/ipython/ipython/milestone/113?closed=1>`__.
249 267
250 268 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
251 269 work on IPython and related libraries.
252 270
253 271 .. _version 8.10.0:
254 272
255 273 IPython 8.10
256 274 ------------
257 275
258 276 Out of schedule release of IPython with minor fixes to patch a potential CVE-2023-24816.
259 277 This is a really low severity CVE that you most likely are not affected by unless:
260 278
261 279 - You are on windows.
262 280 - You have a custom build of Python without ``_ctypes``
263 281 - You cd or start IPython or Jupyter in untrusted directory which names may be
264 282 valid shell commands.
265 283
266 284 You can read more on `the advisory
267 285 <https://github.com/ipython/ipython/security/advisories/GHSA-29gw-9793-fvw7>`__.
268 286
269 287 In addition to fixing this CVE we also fix a couple of outstanding bugs and issues.
270 288
271 289 As usual you can find the full list of PRs on GitHub under `the 8.10 milestone
272 290 <https://github.com/ipython/ipython/milestone/112?closed=1>`__.
273 291
274 292 In Particular:
275 293
276 294 - bump minimum numpy to `>=1.21` version following NEP29. :ghpull:`13930`
277 295 - fix for compatibility with MyPy 1.0. :ghpull:`13933`
278 296 - fix nbgrader stalling when IPython's ``showtraceback`` function is
279 297 monkeypatched. :ghpull:`13934`
280 298
281 299
282 300
283 301 As this release also contains those minimal changes in addition to fixing the
284 302 CVE I decided to bump the minor version anyway.
285 303
286 304 This will not affect the normal release schedule, so IPython 8.11 is due in
287 305 about 2 weeks.
288 306
289 307 .. _version 8.9.0:
290 308
291 309 IPython 8.9.0
292 310 -------------
293 311
294 312 Second release of IPython in 2023, last Friday of the month, we are back on
295 313 track. This is a small release with a few bug-fixes, and improvements, mostly
296 314 with respect to terminal shortcuts.
297 315
298 316
299 317 The biggest improvement for 8.9 is a drastic amelioration of the
300 318 auto-suggestions sponsored by D.E. Shaw and implemented by the more and more
301 319 active contributor `@krassowski <https://github.com/krassowski>`.
302 320
303 321 - ``right`` accepts a single character from suggestion
304 322 - ``ctrl+right`` accepts a semantic token (macos default shortcuts take
305 323 precedence and need to be disabled to make this work)
306 324 - ``backspace`` deletes a character and resumes hinting autosuggestions
307 325 - ``ctrl-left`` accepts suggestion and moves cursor left one character.
308 326 - ``backspace`` deletes a character and resumes hinting autosuggestions
309 327 - ``down`` moves to suggestion to later in history when no lines are present below the cursors.
310 328 - ``up`` moves to suggestion from earlier in history when no lines are present above the cursor.
311 329
312 330 This is best described by the Gif posted by `@krassowski
313 331 <https://github.com/krassowski>`, and in the PR itself :ghpull:`13888`.
314 332
315 333 .. image:: ../_images/autosuggest.gif
316 334
317 335 Please report any feedback in order for us to improve the user experience.
318 336 In particular we are also working on making the shortcuts configurable.
319 337
320 338 If you are interested in better terminal shortcuts, I also invite you to
321 339 participate in issue `13879
322 340 <https://github.com/ipython/ipython/issues/13879>`__.
323 341
324 342
325 343 As we follow `NEP29
326 344 <https://numpy.org/neps/nep-0029-deprecation_policy.html>`__, next version of
327 345 IPython will officially stop supporting numpy 1.20, and will stop supporting
328 346 Python 3.8 after April release.
329 347
330 348 As usual you can find the full list of PRs on GitHub under `the 8.9 milestone
331 349 <https://github.com/ipython/ipython/milestone/111?closed=1>`__.
332 350
333 351
334 352 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
335 353 work on IPython and related libraries.
336 354
337 355 .. _version 8.8.0:
338 356
339 357 IPython 8.8.0
340 358 -------------
341 359
342 360 First release of IPython in 2023 as there was no release at the end of
343 361 December.
344 362
345 363 This is an unusually big release (relatively speaking) with more than 15 Pull
346 364 Requests merged.
347 365
348 366 Of particular interest are:
349 367
350 368 - :ghpull:`13852` that replaces the greedy completer and improves
351 369 completion, in particular for dictionary keys.
352 370 - :ghpull:`13858` that adds ``py.typed`` to ``setup.cfg`` to make sure it is
353 371 bundled in wheels.
354 372 - :ghpull:`13869` that implements tab completions for IPython options in the
355 373 shell when using `argcomplete <https://github.com/kislyuk/argcomplete>`. I
356 374 believe this also needs a recent version of Traitlets.
357 375 - :ghpull:`13865` makes the ``inspector`` class of `InteractiveShell`
358 376 configurable.
359 377 - :ghpull:`13880` that removes minor-version entrypoints as the minor version
360 378 entry points that would be included in the wheel would be the one of the
361 379 Python version that was used to build the ``whl`` file.
362 380
363 381 In no particular order, the rest of the changes update the test suite to be
364 382 compatible with Pygments 2.14, various docfixes, testing on more recent python
365 383 versions and various updates.
366 384
367 385 As usual you can find the full list of PRs on GitHub under `the 8.8 milestone
368 386 <https://github.com/ipython/ipython/milestone/110>`__.
369 387
370 388 Many thanks to @krassowski for the many PRs and @jasongrout for reviewing and
371 389 merging contributions.
372 390
373 391 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
374 392 work on IPython and related libraries.
375 393
376 394 .. _version 8.7.0:
377 395
378 396 IPython 8.7.0
379 397 -------------
380 398
381 399
382 400 Small release of IPython with a couple of bug fixes and new features for this
383 401 month. Next month is the end of year, it is unclear if there will be a release
384 402 close to the new year's eve, or if the next release will be at the end of January.
385 403
386 404 Here are a few of the relevant fixes,
387 405 as usual you can find the full list of PRs on GitHub under `the 8.7 milestone
388 406 <https://github.com/ipython/ipython/pulls?q=milestone%3A8.7>`__.
389 407
390 408
391 409 - :ghpull:`13834` bump the minimum prompt toolkit to 3.0.11.
392 410 - IPython shipped with the ``py.typed`` marker now, and we are progressively
393 411 adding more types. :ghpull:`13831`
394 412 - :ghpull:`13817` add configuration of code blacks formatting.
395 413
396 414
397 415 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
398 416 work on IPython and related libraries.
399 417
400 418
401 419 .. _version 8.6.0:
402 420
403 421 IPython 8.6.0
404 422 -------------
405 423
406 424 Back to a more regular release schedule (at least I try), as Friday is
407 425 already over by more than 24h hours. This is a slightly bigger release with a
408 426 few new features that contain no less than 25 PRs.
409 427
410 428 We'll notably found a couple of non negligible changes:
411 429
412 430 The ``install_ext`` and related functions have been removed after being
413 431 deprecated for years. You can use pip to install extensions. ``pip`` did not
414 432 exist when ``install_ext`` was introduced. You can still load local extensions
415 433 without installing them. Just set your ``sys.path`` for example. :ghpull:`13744`
416 434
417 435 IPython now has extra entry points that use the major *and minor* version of
418 436 python. For some of you this means that you can do a quick ``ipython3.10`` to
419 437 launch IPython from the Python 3.10 interpreter, while still using Python 3.11
420 438 as your main Python. :ghpull:`13743`
421 439
422 440 The completer matcher API has been improved. See :ghpull:`13745`. This should
423 441 improve the type inference and improve dict keys completions in many use case.
424 442 Thanks ``@krassowski`` for all the work, and the D.E. Shaw group for sponsoring
425 443 it.
426 444
427 445 The color of error nodes in tracebacks can now be customized. See
428 446 :ghpull:`13756`. This is a private attribute until someone finds the time to
429 447 properly add a configuration option. Note that with Python 3.11 that also shows
430 448 the relevant nodes in traceback, it would be good to leverage this information
431 449 (plus the "did you mean" info added on attribute errors). But that's likely work
432 450 I won't have time to do before long, so contributions welcome.
433 451
434 452 As we follow NEP 29, we removed support for numpy 1.19 :ghpull:`13760`.
435 453
436 454
437 455 The ``open()`` function present in the user namespace by default will now refuse
438 456 to open the file descriptors 0,1,2 (stdin, out, err), to avoid crashing IPython.
439 457 This mostly occurs in teaching context when incorrect values get passed around.
440 458
441 459
442 460 The ``?``, ``??``, and corresponding ``pinfo``, ``pinfo2`` magics can now find
443 461 objects inside arrays. That is to say, the following now works::
444 462
445 463
446 464 >>> def my_func(*arg, **kwargs):pass
447 465 >>> container = [my_func]
448 466 >>> container[0]?
449 467
450 468
451 469 If ``container`` define a custom ``getitem``, this __will__ trigger the custom
452 470 method. So don't put side effects in your ``getitems``. Thanks to the D.E. Shaw
453 471 group for the request and sponsoring the work.
454 472
455 473
456 474 As usual you can find the full list of PRs on GitHub under `the 8.6 milestone
457 475 <https://github.com/ipython/ipython/pulls?q=milestone%3A8.6>`__.
458 476
459 477 Thanks to all hacktoberfest contributors, please contribute to
460 478 `closember.org <https://closember.org/>`__.
461 479
462 480 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
463 481 work on IPython and related libraries.
464 482
465 483 .. _version 8.5.0:
466 484
467 485 IPython 8.5.0
468 486 -------------
469 487
470 488 First release since a couple of month due to various reasons and timing preventing
471 489 me for sticking to the usual monthly release the last Friday of each month. This
472 490 is of non negligible size as it has more than two dozen PRs with various fixes
473 491 an bug fixes.
474 492
475 493 Many thanks to everybody who contributed PRs for your patience in review and
476 494 merges.
477 495
478 496 Here is a non-exhaustive list of changes that have been implemented for IPython
479 497 8.5.0. As usual you can find the full list of issues and PRs tagged with `the
480 498 8.5 milestone
481 499 <https://github.com/ipython/ipython/pulls?q=is%3Aclosed+milestone%3A8.5+>`__.
482 500
483 501 - Added a shortcut for accepting auto suggestion. The End key shortcut for
484 502 accepting auto-suggestion This binding works in Vi mode too, provided
485 503 ``TerminalInteractiveShell.emacs_bindings_in_vi_insert_mode`` is set to be
486 504 ``True`` :ghpull:`13566`.
487 505
488 506 - No popup in window for latex generation when generating latex (e.g. via
489 507 `_latex_repr_`) no popup window is shows under Windows. :ghpull:`13679`
490 508
491 509 - Fixed error raised when attempting to tab-complete an input string with
492 510 consecutive periods or forward slashes (such as "file:///var/log/...").
493 511 :ghpull:`13675`
494 512
495 513 - Relative filenames in Latex rendering :
496 514 The `latex_to_png_dvipng` command internally generates input and output file
497 515 arguments to `latex` and `dvipis`. These arguments are now generated as
498 516 relative files to the current working directory instead of absolute file
499 517 paths. This solves a problem where the current working directory contains
500 518 characters that are not handled properly by `latex` and `dvips`. There are
501 519 no changes to the user API. :ghpull:`13680`
502 520
503 521 - Stripping decorators bug: Fixed bug which meant that ipython code blocks in
504 522 restructured text documents executed with the ipython-sphinx extension
505 523 skipped any lines of code containing python decorators. :ghpull:`13612`
506 524
507 525 - Allow some modules with frozen dataclasses to be reloaded. :ghpull:`13732`
508 526 - Fix paste magic on wayland. :ghpull:`13671`
509 527 - show maxlen in deque's repr. :ghpull:`13648`
510 528
511 529 Restore line numbers for Input
512 530 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
513 531
514 532 Line number information in tracebacks from input are restored.
515 533 Line numbers from input were removed during the transition to v8 enhanced traceback reporting.
516 534
517 535 So, instead of::
518 536
519 537 ---------------------------------------------------------------------------
520 538 ZeroDivisionError Traceback (most recent call last)
521 539 Input In [3], in <cell line: 1>()
522 540 ----> 1 myfunc(2)
523 541
524 542 Input In [2], in myfunc(z)
525 543 1 def myfunc(z):
526 544 ----> 2 foo.boo(z-1)
527 545
528 546 File ~/code/python/ipython/foo.py:3, in boo(x)
529 547 2 def boo(x):
530 548 ----> 3 return 1/(1-x)
531 549
532 550 ZeroDivisionError: division by zero
533 551
534 552 The error traceback now looks like::
535 553
536 554 ---------------------------------------------------------------------------
537 555 ZeroDivisionError Traceback (most recent call last)
538 556 Cell In [3], line 1
539 557 ----> 1 myfunc(2)
540 558
541 559 Cell In [2], line 2, in myfunc(z)
542 560 1 def myfunc(z):
543 561 ----> 2 foo.boo(z-1)
544 562
545 563 File ~/code/python/ipython/foo.py:3, in boo(x)
546 564 2 def boo(x):
547 565 ----> 3 return 1/(1-x)
548 566
549 567 ZeroDivisionError: division by zero
550 568
551 569 or, with xmode=Plain::
552 570
553 571 Traceback (most recent call last):
554 572 Cell In [12], line 1
555 573 myfunc(2)
556 574 Cell In [6], line 2 in myfunc
557 575 foo.boo(z-1)
558 576 File ~/code/python/ipython/foo.py:3 in boo
559 577 return 1/(1-x)
560 578 ZeroDivisionError: division by zero
561 579
562 580 :ghpull:`13560`
563 581
564 582 New setting to silence warning if working inside a virtual environment
565 583 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
566 584
567 585 Previously, when starting IPython in a virtual environment without IPython installed (so IPython from the global environment is used), the following warning was printed:
568 586
569 587 Attempting to work in a virtualenv. If you encounter problems, please install IPython inside the virtualenv.
570 588
571 589 This warning can be permanently silenced by setting ``c.InteractiveShell.warn_venv`` to ``False`` (the default is ``True``).
572 590
573 591 :ghpull:`13706`
574 592
575 593 -------
576 594
577 595 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
578 596 work on IPython and related libraries.
579 597
580 598
581 599 .. _version 8.4.0:
582 600
583 601 IPython 8.4.0
584 602 -------------
585 603
586 604 As for 7.34, this version contains a single fix: fix uncaught BdbQuit exceptions on ipdb
587 605 exit :ghpull:`13668`, and a single typo fix in documentation: :ghpull:`13682`
588 606
589 607 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
590 608 work on IPython and related libraries.
591 609
592 610
593 611 .. _version 8.3.0:
594 612
595 613 IPython 8.3.0
596 614 -------------
597 615
598 616 - :ghpull:`13625`, using ``?``, ``??``, ``*?`` will not call
599 617 ``set_next_input`` as most frontend allow proper multiline editing and it was
600 618 causing issues for many users of multi-cell frontends. This has been backported to 7.33
601 619
602 620
603 621 - :ghpull:`13600`, ``pre_run_*``-hooks will now have a ``cell_id`` attribute on
604 622 the info object when frontend provides it. This has been backported to 7.33
605 623
606 624 - :ghpull:`13624`, fixed :kbd:`End` key being broken after accepting an
607 625 auto-suggestion.
608 626
609 627 - :ghpull:`13657` fixed an issue where history from different sessions would be mixed.
610 628
611 629 .. _version 8.2.0:
612 630
613 631 IPython 8.2.0
614 632 -------------
615 633
616 634 IPython 8.2 mostly bring bugfixes to IPython.
617 635
618 636 - Auto-suggestion can now be elected with the ``end`` key. :ghpull:`13566`
619 637 - Some traceback issues with ``assert etb is not None`` have been fixed. :ghpull:`13588`
620 638 - History is now pulled from the sqitel database and not from in-memory.
621 639 In particular when using the ``%paste`` magic, the content of the pasted text will
622 640 be part of the history and not the verbatim text ``%paste`` anymore. :ghpull:`13592`
623 641 - Fix ``Ctrl-\\`` exit cleanup :ghpull:`13603`
624 642 - Fixes to ``ultratb`` ipdb support when used outside of IPython. :ghpull:`13498`
625 643
626 644
627 645 I am still trying to fix and investigate :ghissue:`13598`, which seems to be
628 646 random, and would appreciate help if you find a reproducible minimal case. I've
629 647 tried to make various changes to the codebase to mitigate it, but a proper fix
630 648 will be difficult without understanding the cause.
631 649
632 650
633 651 All the issues on pull-requests for this release can be found in the `8.2
634 652 milestone. <https://github.com/ipython/ipython/milestone/100>`__ . And some
635 653 documentation only PR can be found as part of the `7.33 milestone
636 654 <https://github.com/ipython/ipython/milestone/101>`__ (currently not released).
637 655
638 656 Thanks to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
639 657 work on IPython and related libraries.
640 658
641 659 .. _version 8.1.1:
642 660
643 661 IPython 8.1.1
644 662 -------------
645 663
646 664 Fix an issue with virtualenv and Python 3.8 introduced in 8.1
647 665
648 666 Revert :ghpull:`13537` (fix an issue with symlinks in virtualenv) that raises an
649 667 error in Python 3.8, and fixed in a different way in :ghpull:`13559`.
650 668
651 669 .. _version 8.1:
652 670
653 671 IPython 8.1.0
654 672 -------------
655 673
656 674 IPython 8.1 is the first minor release after 8.0 and fixes a number of bugs and
657 675 updates a few behaviors that were problematic with the 8.0 as with many new major
658 676 release.
659 677
660 678 Note that beyond the changes listed here, IPython 8.1.0 also contains all the
661 679 features listed in :ref:`version 7.32`.
662 680
663 681 - Misc and multiple fixes around quotation auto-closing. It is now disabled by
664 682 default. Run with ``TerminalInteractiveShell.auto_match=True`` to re-enabled
665 683 - Require pygments>=2.4.0 :ghpull:`13459`, this was implicit in the code, but
666 684 is now explicit in ``setup.cfg``/``setup.py``
667 685 - Docs improvement of ``core.magic_arguments`` examples. :ghpull:`13433`
668 686 - Multi-line edit executes too early with await. :ghpull:`13424`
669 687
670 688 - ``black`` is back as an optional dependency, and autoformatting disabled by
671 689 default until some fixes are implemented (black improperly reformat magics).
672 690 :ghpull:`13471` Additionally the ability to use ``yapf`` as a code
673 691 reformatter has been added :ghpull:`13528` . You can use
674 692 ``TerminalInteractiveShell.autoformatter="black"``,
675 693 ``TerminalInteractiveShell.autoformatter="yapf"`` to re-enable auto formating
676 694 with black, or switch to yapf.
677 695
678 696 - Fix and issue where ``display`` was not defined.
679 697
680 698 - Auto suggestions are now configurable. Currently only
681 699 ``AutoSuggestFromHistory`` (default) and ``None``. new provider contribution
682 700 welcomed. :ghpull:`13475`
683 701
684 702 - multiple packaging/testing improvement to simplify downstream packaging
685 703 (xfail with reasons, try to not access network...).
686 704
687 705 - Update deprecation. ``InteractiveShell.magic`` internal method has been
688 706 deprecated for many years but did not emit a warning until now.
689 707
690 708 - internal ``appended_to_syspath`` context manager has been deprecated.
691 709
692 710 - fix an issue with symlinks in virtualenv :ghpull:`13537` (Reverted in 8.1.1)
693 711
694 712 - Fix an issue with vim mode, where cursor would not be reset on exit :ghpull:`13472`
695 713
696 714 - ipython directive now remove only known pseudo-decorators :ghpull:`13532`
697 715
698 716 - ``IPython/lib/security`` which used to be used for jupyter notebook has been
699 717 removed.
700 718
701 719 - Fix an issue where ``async with`` would execute on new lines. :ghpull:`13436`
702 720
703 721
704 722 We want to remind users that IPython is part of the Jupyter organisations, and
705 723 thus governed by a Code of Conduct. Some of the behavior we have seen on GitHub is not acceptable.
706 724 Abuse and non-respectful comments on discussion will not be tolerated.
707 725
708 726 Many thanks to all the contributors to this release, many of the above fixed issues and
709 727 new features were done by first time contributors, showing there is still
710 728 plenty of easy contribution possible in IPython
711 729 . You can find all individual contributions
712 730 to this milestone `on github <https://github.com/ipython/ipython/milestone/91>`__.
713 731
714 732 Thanks as well to the `D. E. Shaw group <https://deshaw.com/>`__ for sponsoring
715 733 work on IPython and related libraries. In particular the Lazy autoloading of
716 734 magics that you will find described in the 7.32 release notes.
717 735
718 736
719 737 .. _version 8.0.1:
720 738
721 739 IPython 8.0.1 (CVE-2022-21699)
722 740 ------------------------------
723 741
724 742 IPython 8.0.1, 7.31.1 and 5.11 are security releases that change some default
725 743 values in order to prevent potential Execution with Unnecessary Privileges.
726 744
727 745 Almost all version of IPython looks for configuration and profiles in current
728 746 working directory. Since IPython was developed before pip and environments
729 747 existed it was used a convenient way to load code/packages in a project
730 748 dependant way.
731 749
732 750 In 2022, it is not necessary anymore, and can lead to confusing behavior where
733 751 for example cloning a repository and starting IPython or loading a notebook from
734 752 any Jupyter-Compatible interface that has ipython set as a kernel can lead to
735 753 code execution.
736 754
737 755
738 756 I did not find any standard way for packaged to advertise CVEs they fix, I'm
739 757 thus trying to add a ``__patched_cves__`` attribute to the IPython module that
740 758 list the CVEs that should have been fixed. This attribute is informational only
741 759 as if a executable has a flaw, this value can always be changed by an attacker.
742 760
743 761 .. code::
744 762
745 763 In [1]: import IPython
746 764
747 765 In [2]: IPython.__patched_cves__
748 766 Out[2]: {'CVE-2022-21699'}
749 767
750 768 In [3]: 'CVE-2022-21699' in IPython.__patched_cves__
751 769 Out[3]: True
752 770
753 771 Thus starting with this version:
754 772
755 773 - The current working directory is not searched anymore for profiles or
756 774 configurations files.
757 775 - Added a ``__patched_cves__`` attribute (set of strings) to IPython module that contain
758 776 the list of fixed CVE. This is informational only.
759 777
760 778 Further details can be read on the `GitHub Advisory <https://github.com/ipython/ipython/security/advisories/GHSA-pq7m-3gw7-gq5x>`__
761 779
762 780
763 781 .. _version 8.0:
764 782
765 783 IPython 8.0
766 784 -----------
767 785
768 786 IPython 8.0 is bringing a large number of new features and improvements to both the
769 787 user of the terminal and of the kernel via Jupyter. The removal of compatibility
770 788 with an older version of Python is also the opportunity to do a couple of
771 789 performance improvements in particular with respect to startup time.
772 790 The 8.x branch started diverging from its predecessor around IPython 7.12
773 791 (January 2020).
774 792
775 793 This release contains 250+ pull requests, in addition to many of the features
776 794 and backports that have made it to the 7.x branch. Please see the
777 795 `8.0 milestone <https://github.com/ipython/ipython/milestone/73?closed=1>`__ for the full list of pull requests.
778 796
779 797 Please feel free to send pull requests to update those notes after release,
780 798 I have likely forgotten a few things reviewing 250+ PRs.
781 799
782 800 Dependencies changes/downstream packaging
783 801 -----------------------------------------
784 802
785 803 Most of our building steps have been changed to be (mostly) declarative
786 804 and follow PEP 517. We are trying to completely remove ``setup.py`` (:ghpull:`13238`) and are
787 805 looking for help to do so.
788 806
789 807 - minimum supported ``traitlets`` version is now 5+
790 808 - we now require ``stack_data``
791 809 - minimal Python is now 3.8
792 810 - ``nose`` is not a testing requirement anymore
793 811 - ``pytest`` replaces nose.
794 812 - ``iptest``/``iptest3`` cli entrypoints do not exist anymore.
795 813 - the minimum officially ​supported ``numpy`` version has been bumped, but this should
796 814 not have much effect on packaging.
797 815
798 816
799 817 Deprecation and removal
800 818 -----------------------
801 819
802 820 We removed almost all features, arguments, functions, and modules that were
803 821 marked as deprecated between IPython 1.0 and 5.0. As a reminder, 5.0 was released
804 822 in 2016, and 1.0 in 2013. Last release of the 5 branch was 5.10.0, in May 2020.
805 823 The few remaining deprecated features we left have better deprecation warnings
806 824 or have been turned into explicit errors for better error messages.
807 825
808 826 I will use this occasion to add the following requests to anyone emitting a
809 827 deprecation warning:
810 828
811 829 - Please add at least ``stacklevel=2`` so that the warning is emitted into the
812 830 caller context, and not the callee one.
813 831 - Please add **since which version** something is deprecated.
814 832
815 833 As a side note, it is much easier to conditionally compare version
816 834 numbers rather than using ``try/except`` when functionality changes with a version.
817 835
818 836 I won't list all the removed features here, but modules like ``IPython.kernel``,
819 837 which was just a shim module around ``ipykernel`` for the past 8 years, have been
820 838 removed, and so many other similar things that pre-date the name **Jupyter**
821 839 itself.
822 840
823 841 We no longer need to add ``IPython.extensions`` to the PYTHONPATH because that is being
824 842 handled by ``load_extension``.
825 843
826 844 We are also removing ``Cythonmagic``, ``sympyprinting`` and ``rmagic`` as they are now in
827 845 other packages and no longer need to be inside IPython.
828 846
829 847
830 848 Documentation
831 849 -------------
832 850
833 851 The majority of our docstrings have now been reformatted and automatically fixed by
834 852 the experimental `VΓ©lin <https://pypi.org/project/velin/>`_ project to conform
835 853 to numpydoc.
836 854
837 855 Type annotations
838 856 ----------------
839 857
840 858 While IPython itself is highly dynamic and can't be completely typed, many of
841 859 the functions now have type annotations, and part of the codebase is now checked
842 860 by mypy.
843 861
844 862
845 863 Featured changes
846 864 ----------------
847 865
848 866 Here is a features list of changes in IPython 8.0. This is of course non-exhaustive.
849 867 Please note as well that many features have been added in the 7.x branch as well
850 868 (and hence why you want to read the 7.x what's new notes), in particular
851 869 features contributed by QuantStack (with respect to debugger protocol and Xeus
852 870 Python), as well as many debugger features that I was pleased to implement as
853 871 part of my work at QuanSight and sponsored by DE Shaw.
854 872
855 873 Traceback improvements
856 874 ~~~~~~~~~~~~~~~~~~~~~~
857 875
858 876 Previously, error tracebacks for errors happening in code cells were showing a
859 877 hash, the one used for compiling the Python AST::
860 878
861 879 In [1]: def foo():
862 880 ...: return 3 / 0
863 881 ...:
864 882
865 883 In [2]: foo()
866 884 ---------------------------------------------------------------------------
867 885 ZeroDivisionError Traceback (most recent call last)
868 886 <ipython-input-2-c19b6d9633cf> in <module>
869 887 ----> 1 foo()
870 888
871 889 <ipython-input-1-1595a74c32d5> in foo()
872 890 1 def foo():
873 891 ----> 2 return 3 / 0
874 892 3
875 893
876 894 ZeroDivisionError: division by zero
877 895
878 896 The error traceback is now correctly formatted, showing the cell number in which the error happened::
879 897
880 898 In [1]: def foo():
881 899 ...: return 3 / 0
882 900 ...:
883 901
884 902 Input In [2]: foo()
885 903 ---------------------------------------------------------------------------
886 904 ZeroDivisionError Traceback (most recent call last)
887 905 input In [2], in <module>
888 906 ----> 1 foo()
889 907
890 908 Input In [1], in foo()
891 909 1 def foo():
892 910 ----> 2 return 3 / 0
893 911
894 912 ZeroDivisionError: division by zero
895 913
896 914 The ``stack_data`` package has been integrated, which provides smarter information in the traceback;
897 915 in particular it will highlight the AST node where an error occurs which can help to quickly narrow down errors.
898 916
899 917 For example in the following snippet::
900 918
901 919 def foo(i):
902 920 x = [[[0]]]
903 921 return x[0][i][0]
904 922
905 923
906 924 def bar():
907 925 return foo(0) + foo(
908 926 1
909 927 ) + foo(2)
910 928
911 929
912 930 calling ``bar()`` would raise an ``IndexError`` on the return line of ``foo``,
913 931 and IPython 8.0 is capable of telling you where the index error occurs::
914 932
915 933
916 934 IndexError
917 935 Input In [2], in <module>
918 936 ----> 1 bar()
919 937 ^^^^^
920 938
921 939 Input In [1], in bar()
922 940 6 def bar():
923 941 ----> 7 return foo(0) + foo(
924 942 ^^^^
925 943 8 1
926 944 ^^^^^^^^
927 945 9 ) + foo(2)
928 946 ^^^^
929 947
930 948 Input In [1], in foo(i)
931 949 1 def foo(i):
932 950 2 x = [[[0]]]
933 951 ----> 3 return x[0][i][0]
934 952 ^^^^^^^
935 953
936 954 The corresponding locations marked here with ``^`` will show up highlighted in
937 955 the terminal and notebooks.
938 956
939 957 Finally, a colon ``::`` and line number is appended after a filename in
940 958 traceback::
941 959
942 960
943 961 ZeroDivisionError Traceback (most recent call last)
944 962 File ~/error.py:4, in <module>
945 963 1 def f():
946 964 2 1/0
947 965 ----> 4 f()
948 966
949 967 File ~/error.py:2, in f()
950 968 1 def f():
951 969 ----> 2 1/0
952 970
953 971 Many terminals and editors have integrations enabling you to directly jump to the
954 972 relevant file/line when this syntax is used, so this small addition may have a high
955 973 impact on productivity.
956 974
957 975
958 976 Autosuggestions
959 977 ~~~~~~~~~~~~~~~
960 978
961 979 Autosuggestion is a very useful feature available in `fish <https://fishshell.com/>`__, `zsh <https://en.wikipedia.org/wiki/Z_shell>`__, and `prompt-toolkit <https://python-prompt-toolkit.readthedocs.io/en/master/pages/asking_for_input.html#auto-suggestion>`__.
962 980
963 981 `Ptpython <https://github.com/prompt-toolkit/ptpython#ptpython>`__ allows users to enable this feature in
964 982 `ptpython/config.py <https://github.com/prompt-toolkit/ptpython/blob/master/examples/ptpython_config/config.py#L90>`__.
965 983
966 984 This feature allows users to accept autosuggestions with ctrl e, ctrl f,
967 985 or right arrow as described below.
968 986
969 987 1. Start ipython
970 988
971 989 .. image:: ../_images/8.0/auto_suggest_1_prompt_no_text.png
972 990
973 991 2. Run ``print("hello")``
974 992
975 993 .. image:: ../_images/8.0/auto_suggest_2_print_hello_suggest.png
976 994
977 995 3. start typing ``print`` again to see the autosuggestion
978 996
979 997 .. image:: ../_images/8.0/auto_suggest_3_print_hello_suggest.png
980 998
981 999 4. Press ``ctrl-f``, or ``ctrl-e``, or ``right-arrow`` to accept the suggestion
982 1000
983 1001 .. image:: ../_images/8.0/auto_suggest_4_print_hello.png
984 1002
985 1003 You can also complete word by word:
986 1004
987 1005 1. Run ``def say_hello(): print("hello")``
988 1006
989 1007 .. image:: ../_images/8.0/auto_suggest_second_prompt.png
990 1008
991 1009 2. Start typing the first letter if ``def`` to see the autosuggestion
992 1010
993 1011 .. image:: ../_images/8.0/auto_suggest_d_phantom.png
994 1012
995 1013 3. Press ``alt-f`` (or ``escape`` followed by ``f``), to accept the first word of the suggestion
996 1014
997 1015 .. image:: ../_images/8.0/auto_suggest_def_phantom.png
998 1016
999 1017 Importantly, this feature does not interfere with tab completion:
1000 1018
1001 1019 1. After running ``def say_hello(): print("hello")``, press d
1002 1020
1003 1021 .. image:: ../_images/8.0/auto_suggest_d_phantom.png
1004 1022
1005 1023 2. Press Tab to start tab completion
1006 1024
1007 1025 .. image:: ../_images/8.0/auto_suggest_d_completions.png
1008 1026
1009 1027 3A. Press Tab again to select the first option
1010 1028
1011 1029 .. image:: ../_images/8.0/auto_suggest_def_completions.png
1012 1030
1013 1031 3B. Press ``alt f`` (``escape``, ``f``) to accept to accept the first word of the suggestion
1014 1032
1015 1033 .. image:: ../_images/8.0/auto_suggest_def_phantom.png
1016 1034
1017 1035 3C. Press ``ctrl-f`` or ``ctrl-e`` to accept the entire suggestion
1018 1036
1019 1037 .. image:: ../_images/8.0/auto_suggest_match_parens.png
1020 1038
1021 1039
1022 1040 Currently, autosuggestions are only shown in the emacs or vi insert editing modes:
1023 1041
1024 1042 - The ctrl e, ctrl f, and alt f shortcuts work by default in emacs mode.
1025 1043 - To use these shortcuts in vi insert mode, you will have to create `custom keybindings in your config.py <https://github.com/mskar/setup/commit/2892fcee46f9f80ef7788f0749edc99daccc52f4/>`__.
1026 1044
1027 1045
1028 1046 Show pinfo information in ipdb using "?" and "??"
1029 1047 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1030 1048
1031 1049 In IPDB, it is now possible to show the information about an object using "?"
1032 1050 and "??", in much the same way that it can be done when using the IPython prompt::
1033 1051
1034 1052 ipdb> partial?
1035 1053 Init signature: partial(self, /, *args, **kwargs)
1036 1054 Docstring:
1037 1055 partial(func, *args, **keywords) - new function with partial application
1038 1056 of the given arguments and keywords.
1039 1057 File: ~/.pyenv/versions/3.8.6/lib/python3.8/functools.py
1040 1058 Type: type
1041 1059 Subclasses:
1042 1060
1043 1061 Previously, ``pinfo`` or ``pinfo2`` command had to be used for this purpose.
1044 1062
1045 1063
1046 1064 Autoreload 3 feature
1047 1065 ~~~~~~~~~~~~~~~~~~~~
1048 1066
1049 1067 Example: When an IPython session is run with the 'autoreload' extension loaded,
1050 1068 you will now have the option '3' to select, which means the following:
1051 1069
1052 1070 1. replicate all functionality from option 2
1053 1071 2. autoload all new funcs/classes/enums/globals from the module when they are added
1054 1072 3. autoload all newly imported funcs/classes/enums/globals from external modules
1055 1073
1056 1074 Try ``%autoreload 3`` in an IPython session after running ``%load_ext autoreload``.
1057 1075
1058 1076 For more information please see the following unit test : ``extensions/tests/test_autoreload.py:test_autoload_newly_added_objects``
1059 1077
1060 1078 Auto formatting with black in the CLI
1061 1079 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1062 1080
1063 1081 This feature was present in 7.x, but disabled by default.
1064 1082
1065 1083 In 8.0, input was automatically reformatted with Black when black was installed.
1066 1084 This feature has been reverted for the time being.
1067 1085 You can re-enable it by setting ``TerminalInteractiveShell.autoformatter`` to ``"black"``
1068 1086
1069 1087 History Range Glob feature
1070 1088 ~~~~~~~~~~~~~~~~~~~~~~~~~~
1071 1089
1072 1090 Previously, when using ``%history``, users could specify either
1073 1091 a range of sessions and lines, for example:
1074 1092
1075 1093 .. code-block:: python
1076 1094
1077 1095 ~8/1-~6/5 # see history from the first line of 8 sessions ago,
1078 1096 # to the fifth line of 6 sessions ago.``
1079 1097
1080 1098 Or users could specify a glob pattern:
1081 1099
1082 1100 .. code-block:: python
1083 1101
1084 1102 -g <pattern> # glob ALL history for the specified pattern.
1085 1103
1086 1104 However users could *not* specify both.
1087 1105
1088 1106 If a user *did* specify both a range and a glob pattern,
1089 1107 then the glob pattern would be used (globbing *all* history) *and the range would be ignored*.
1090 1108
1091 1109 With this enhancement, if a user specifies both a range and a glob pattern, then the glob pattern will be applied to the specified range of history.
1092 1110
1093 1111 Don't start a multi-line cell with sunken parenthesis
1094 1112 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1095 1113
1096 1114 From now on, IPython will not ask for the next line of input when given a single
1097 1115 line with more closing than opening brackets. For example, this means that if
1098 1116 you (mis)type ``]]`` instead of ``[]``, a ``SyntaxError`` will show up, instead of
1099 1117 the ``...:`` prompt continuation.
1100 1118
1101 1119 IPython shell for ipdb interact
1102 1120 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1103 1121
1104 1122 The ipdb ``interact`` starts an IPython shell instead of Python's built-in ``code.interact()``.
1105 1123
1106 1124 Automatic Vi prompt stripping
1107 1125 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1108 1126
1109 1127 When pasting code into IPython, it will strip the leading prompt characters if
1110 1128 there are any. For example, you can paste the following code into the console -
1111 1129 it will still work, even though each line is prefixed with prompts (``In``,
1112 1130 ``Out``)::
1113 1131
1114 1132 In [1]: 2 * 2 == 4
1115 1133 Out[1]: True
1116 1134
1117 1135 In [2]: print("This still works as pasted")
1118 1136
1119 1137
1120 1138 Previously, this was not the case for the Vi-mode prompts::
1121 1139
1122 1140 In [1]: [ins] In [13]: 2 * 2 == 4
1123 1141 ...: Out[13]: True
1124 1142 ...:
1125 1143 File "<ipython-input-1-727bb88eaf33>", line 1
1126 1144 [ins] In [13]: 2 * 2 == 4
1127 1145 ^
1128 1146 SyntaxError: invalid syntax
1129 1147
1130 1148 This is now fixed, and Vi prompt prefixes - ``[ins]`` and ``[nav]`` - are
1131 1149 skipped just as the normal ``In`` would be.
1132 1150
1133 1151 IPython shell can be started in the Vi mode using ``ipython --TerminalInteractiveShell.editing_mode=vi``,
1134 1152 You should be able to change mode dynamically with ``%config TerminalInteractiveShell.editing_mode='vi'``
1135 1153
1136 1154 Empty History Ranges
1137 1155 ~~~~~~~~~~~~~~~~~~~~
1138 1156
1139 1157 A number of magics that take history ranges can now be used with an empty
1140 1158 range. These magics are:
1141 1159
1142 1160 * ``%save``
1143 1161 * ``%load``
1144 1162 * ``%pastebin``
1145 1163 * ``%pycat``
1146 1164
1147 1165 Using them this way will make them take the history of the current session up
1148 1166 to the point of the magic call (such that the magic itself will not be
1149 1167 included).
1150 1168
1151 1169 Therefore it is now possible to save the whole history to a file using
1152 1170 ``%save <filename>``, load and edit it using ``%load`` (makes for a nice usage
1153 1171 when followed with :kbd:`F2`), send it to `dpaste.org <http://dpast.org>`_ using
1154 1172 ``%pastebin``, or view the whole thing syntax-highlighted with a single
1155 1173 ``%pycat``.
1156 1174
1157 1175
1158 1176 Windows timing implementation: Switch to process_time
1159 1177 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1160 1178 Timing on Windows, for example with ``%%time``, was changed from being based on ``time.perf_counter``
1161 1179 (which counted time even when the process was sleeping) to being based on ``time.process_time`` instead
1162 1180 (which only counts CPU time). This brings it closer to the behavior on Linux. See :ghpull:`12984`.
1163 1181
1164 1182 Miscellaneous
1165 1183 ~~~~~~~~~~~~~
1166 1184 - Non-text formatters are not disabled in the terminal, which should simplify
1167 1185 writing extensions displaying images or other mimetypes in supporting terminals.
1168 1186 :ghpull:`12315`
1169 1187 - It is now possible to automatically insert matching brackets in Terminal IPython using the
1170 1188 ``TerminalInteractiveShell.auto_match=True`` option. :ghpull:`12586`
1171 1189 - We are thinking of deprecating the current ``%%javascript`` magic in favor of a better replacement. See :ghpull:`13376`.
1172 1190 - ``~`` is now expanded when part of a path in most magics :ghpull:`13385`
1173 1191 - ``%/%%timeit`` magic now adds a comma every thousands to make reading a long number easier :ghpull:`13379`
1174 1192 - ``"info"`` messages can now be customised to hide some fields :ghpull:`13343`
1175 1193 - ``collections.UserList`` now pretty-prints :ghpull:`13320`
1176 1194 - The debugger now has a persistent history, which should make it less
1177 1195 annoying to retype commands :ghpull:`13246`
1178 1196 - ``!pip`` ``!conda`` ``!cd`` or ``!ls`` are likely doing the wrong thing. We
1179 1197 now warn users if they use one of those commands. :ghpull:`12954`
1180 1198 - Make ``%precision`` work for ``numpy.float64`` type :ghpull:`12902`
1181 1199
1182 1200 Re-added support for XDG config directories
1183 1201 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1184 1202
1185 1203 XDG support through the years comes and goes. There is a tension between having
1186 1204 an identical location for configuration in all platforms versus having simple instructions.
1187 1205 After initial failures a couple of years ago, IPython was modified to automatically migrate XDG
1188 1206 config files back into ``~/.ipython``. That migration code has now been removed.
1189 1207 IPython now checks the XDG locations, so if you _manually_ move your config
1190 1208 files to your preferred location, IPython will not move them back.
1191 1209
1192 1210
1193 1211 Preparing for Python 3.10
1194 1212 -------------------------
1195 1213
1196 1214 To prepare for Python 3.10, we have started working on removing reliance and
1197 1215 any dependency that is not compatible with Python 3.10. This includes migrating our
1198 1216 test suite to pytest and starting to remove nose. This also means that the
1199 1217 ``iptest`` command is now gone and all testing is via pytest.
1200 1218
1201 1219 This was in large part thanks to the NumFOCUS Small Developer grant, which enabled us to
1202 1220 allocate \$4000 to hire `Nikita Kniazev (@Kojoley) <https://github.com/Kojoley>`_,
1203 1221 who did a fantastic job at updating our code base, migrating to pytest, pushing
1204 1222 our coverage, and fixing a large number of bugs. I highly recommend contacting
1205 1223 them if you need help with C++ and Python projects.
1206 1224
1207 1225 You can find all relevant issues and PRs with `the SDG 2021 tag <https://github.com/ipython/ipython/issues?q=label%3A%22Numfocus+SDG+2021%22+>`__
1208 1226
1209 1227 Removing support for older Python versions
1210 1228 ------------------------------------------
1211 1229
1212 1230
1213 1231 We are removing support for Python up through 3.7, allowing internal code to use the more
1214 1232 efficient ``pathlib`` and to make better use of type annotations.
1215 1233
1216 1234 .. image:: ../_images/8.0/pathlib_pathlib_everywhere.jpg
1217 1235 :alt: "Meme image of Toy Story with Woody and Buzz, with the text 'pathlib, pathlib everywhere'"
1218 1236
1219 1237
1220 1238 We had about 34 PRs only to update some logic to update some functions from managing strings to
1221 1239 using Pathlib.
1222 1240
1223 1241 The completer has also seen significant updates and now makes use of newer Jedi APIs,
1224 1242 offering faster and more reliable tab completion.
1225 1243
1226 1244 Misc Statistics
1227 1245 ---------------
1228 1246
1229 1247 Here are some numbers::
1230 1248
1231 1249 7.x: 296 files, 12561 blank lines, 20282 comments, 35142 line of code.
1232 1250 8.0: 252 files, 12053 blank lines, 19232 comments, 34505 line of code.
1233 1251
1234 1252 $ git diff --stat 7.x...master | tail -1
1235 1253 340 files changed, 13399 insertions(+), 12421 deletions(-)
1236 1254
1237 1255 We have commits from 162 authors, who contributed 1916 commits in 23 month, excluding merges (to not bias toward
1238 1256 maintainers pushing buttons).::
1239 1257
1240 1258 $ git shortlog -s --no-merges 7.x...master | sort -nr
1241 1259 535 Matthias Bussonnier
1242 1260 86 Nikita Kniazev
1243 1261 69 Blazej Michalik
1244 1262 49 Samuel Gaist
1245 1263 27 Itamar Turner-Trauring
1246 1264 18 Spas Kalaydzhisyki
1247 1265 17 Thomas Kluyver
1248 1266 17 Quentin Peter
1249 1267 17 James Morris
1250 1268 17 Artur Svistunov
1251 1269 15 Bart Skowron
1252 1270 14 Alex Hall
1253 1271 13 rushabh-v
1254 1272 13 Terry Davis
1255 1273 13 Benjamin Ragan-Kelley
1256 1274 8 martinRenou
1257 1275 8 farisachugthai
1258 1276 7 dswij
1259 1277 7 Gal B
1260 1278 7 Corentin Cadiou
1261 1279 6 yuji96
1262 1280 6 Martin Skarzynski
1263 1281 6 Justin Palmer
1264 1282 6 Daniel Goldfarb
1265 1283 6 Ben Greiner
1266 1284 5 Sammy Al Hashemi
1267 1285 5 Paul Ivanov
1268 1286 5 Inception95
1269 1287 5 Eyenpi
1270 1288 5 Douglas Blank
1271 1289 5 Coco Mishra
1272 1290 5 Bibo Hao
1273 1291 5 AndrΓ© A. Gomes
1274 1292 5 Ahmed Fasih
1275 1293 4 takuya fujiwara
1276 1294 4 palewire
1277 1295 4 Thomas A Caswell
1278 1296 4 Talley Lambert
1279 1297 4 Scott Sanderson
1280 1298 4 Ram Rachum
1281 1299 4 Nick Muoh
1282 1300 4 Nathan Goldbaum
1283 1301 4 Mithil Poojary
1284 1302 4 Michael T
1285 1303 4 Jakub Klus
1286 1304 4 Ian Castleden
1287 1305 4 Eli Rykoff
1288 1306 4 Ashwin Vishnu
1289 1307 3 谭九鼎
1290 1308 3 sleeping
1291 1309 3 Sylvain Corlay
1292 1310 3 Peter Corke
1293 1311 3 Paul Bissex
1294 1312 3 Matthew Feickert
1295 1313 3 Fernando Perez
1296 1314 3 Eric Wieser
1297 1315 3 Daniel Mietchen
1298 1316 3 Aditya Sathe
1299 1317 3 007vedant
1300 1318 2 rchiodo
1301 1319 2 nicolaslazo
1302 1320 2 luttik
1303 1321 2 gorogoroumaru
1304 1322 2 foobarbyte
1305 1323 2 bar-hen
1306 1324 2 Theo Ouzhinski
1307 1325 2 Strawkage
1308 1326 2 Samreen Zarroug
1309 1327 2 Pete Blois
1310 1328 2 Meysam Azad
1311 1329 2 Matthieu Ancellin
1312 1330 2 Mark Schmitz
1313 1331 2 Maor Kleinberger
1314 1332 2 MRCWirtz
1315 1333 2 Lumir Balhar
1316 1334 2 Julien Rabinow
1317 1335 2 Juan Luis Cano RodrΓ­guez
1318 1336 2 Joyce Er
1319 1337 2 Jakub
1320 1338 2 Faris A Chugthai
1321 1339 2 Ethan Madden
1322 1340 2 Dimitri Papadopoulos
1323 1341 2 Diego Fernandez
1324 1342 2 Daniel Shimon
1325 1343 2 Coco Bennett
1326 1344 2 Carlos Cordoba
1327 1345 2 Boyuan Liu
1328 1346 2 BaoGiang HoangVu
1329 1347 2 Augusto
1330 1348 2 Arthur Svistunov
1331 1349 2 Arthur Moreira
1332 1350 2 Ali Nabipour
1333 1351 2 Adam Hackbarth
1334 1352 1 richard
1335 1353 1 linar-jether
1336 1354 1 lbennett
1337 1355 1 juacrumar
1338 1356 1 gpotter2
1339 1357 1 digitalvirtuoso
1340 1358 1 dalthviz
1341 1359 1 Yonatan Goldschmidt
1342 1360 1 Tomasz KΕ‚oczko
1343 1361 1 Tobias Bengfort
1344 1362 1 Timur Kushukov
1345 1363 1 Thomas
1346 1364 1 Snir Broshi
1347 1365 1 Shao Yang Hong
1348 1366 1 Sanjana-03
1349 1367 1 Romulo Filho
1350 1368 1 Rodolfo Carvalho
1351 1369 1 Richard Shadrach
1352 1370 1 Reilly Tucker Siemens
1353 1371 1 Rakessh Roshan
1354 1372 1 Piers Titus van der Torren
1355 1373 1 PhanatosZou
1356 1374 1 Pavel Safronov
1357 1375 1 Paulo S. Costa
1358 1376 1 Paul McCarthy
1359 1377 1 NotWearingPants
1360 1378 1 Naelson Douglas
1361 1379 1 Michael Tiemann
1362 1380 1 Matt Wozniski
1363 1381 1 Markus Wageringel
1364 1382 1 Marcus Wirtz
1365 1383 1 Marcio Mazza
1366 1384 1 LumΓ­r 'Frenzy' Balhar
1367 1385 1 Lightyagami1
1368 1386 1 Leon Anavi
1369 1387 1 LeafyLi
1370 1388 1 L0uisJ0shua
1371 1389 1 Kyle Cutler
1372 1390 1 Krzysztof Cybulski
1373 1391 1 Kevin Kirsche
1374 1392 1 KIU Shueng Chuan
1375 1393 1 Jonathan Slenders
1376 1394 1 Jay Qi
1377 1395 1 Jake VanderPlas
1378 1396 1 Iwan Briquemont
1379 1397 1 Hussaina Begum Nandyala
1380 1398 1 Gordon Ball
1381 1399 1 Gabriel Simonetto
1382 1400 1 Frank Tobia
1383 1401 1 Erik
1384 1402 1 Elliott Sales de Andrade
1385 1403 1 Daniel Hahler
1386 1404 1 Dan Green-Leipciger
1387 1405 1 Dan Green
1388 1406 1 Damian Yurzola
1389 1407 1 Coon, Ethan T
1390 1408 1 Carol Willing
1391 1409 1 Brian Lee
1392 1410 1 Brendan Gerrity
1393 1411 1 Blake Griffin
1394 1412 1 Bastian Ebeling
1395 1413 1 Bartosz Telenczuk
1396 1414 1 Ankitsingh6299
1397 1415 1 Andrew Port
1398 1416 1 Andrew J. Hesford
1399 1417 1 Albert Zhang
1400 1418 1 Adam Johnson
1401 1419
1402 1420 This does not, of course, represent non-code contributions, for which we are also grateful.
1403 1421
1404 1422
1405 1423 API Changes using Frappuccino
1406 1424 -----------------------------
1407 1425
1408 1426 This is an experimental exhaustive API difference using `Frappuccino <https://pypi.org/project/frappuccino/>`_
1409 1427
1410 1428
1411 1429 The following items are new in IPython 8.0 ::
1412 1430
1413 1431 + IPython.core.async_helpers.get_asyncio_loop()
1414 1432 + IPython.core.completer.Dict
1415 1433 + IPython.core.completer.Pattern
1416 1434 + IPython.core.completer.Sequence
1417 1435 + IPython.core.completer.__skip_doctest__
1418 1436 + IPython.core.debugger.Pdb.precmd(self, line)
1419 1437 + IPython.core.debugger.__skip_doctest__
1420 1438 + IPython.core.display.__getattr__(name)
1421 1439 + IPython.core.display.warn
1422 1440 + IPython.core.display_functions
1423 1441 + IPython.core.display_functions.DisplayHandle
1424 1442 + IPython.core.display_functions.DisplayHandle.display(self, obj, **kwargs)
1425 1443 + IPython.core.display_functions.DisplayHandle.update(self, obj, **kwargs)
1426 1444 + IPython.core.display_functions.__all__
1427 1445 + IPython.core.display_functions.__builtins__
1428 1446 + IPython.core.display_functions.__cached__
1429 1447 + IPython.core.display_functions.__doc__
1430 1448 + IPython.core.display_functions.__file__
1431 1449 + IPython.core.display_functions.__loader__
1432 1450 + IPython.core.display_functions.__name__
1433 1451 + IPython.core.display_functions.__package__
1434 1452 + IPython.core.display_functions.__spec__
1435 1453 + IPython.core.display_functions.b2a_hex
1436 1454 + IPython.core.display_functions.clear_output(wait=False)
1437 1455 + IPython.core.display_functions.display(*objs, include='None', exclude='None', metadata='None', transient='None', display_id='None', raw=False, clear=False, **kwargs)
1438 1456 + IPython.core.display_functions.publish_display_data(data, metadata='None', source='<deprecated>', *, transient='None', **kwargs)
1439 1457 + IPython.core.display_functions.update_display(obj, *, display_id, **kwargs)
1440 1458 + IPython.core.extensions.BUILTINS_EXTS
1441 1459 + IPython.core.inputtransformer2.has_sunken_brackets(tokens)
1442 1460 + IPython.core.interactiveshell.Callable
1443 1461 + IPython.core.interactiveshell.__annotations__
1444 1462 + IPython.core.ultratb.List
1445 1463 + IPython.core.ultratb.Tuple
1446 1464 + IPython.lib.pretty.CallExpression
1447 1465 + IPython.lib.pretty.CallExpression.factory(name)
1448 1466 + IPython.lib.pretty.RawStringLiteral
1449 1467 + IPython.lib.pretty.RawText
1450 1468 + IPython.terminal.debugger.TerminalPdb.do_interact(self, arg)
1451 1469 + IPython.terminal.embed.Set
1452 1470
1453 1471 The following items have been removed (or moved to superclass)::
1454 1472
1455 1473 - IPython.core.application.BaseIPythonApplication.initialize_subcommand
1456 1474 - IPython.core.completer.Sentinel
1457 1475 - IPython.core.completer.skip_doctest
1458 1476 - IPython.core.debugger.Tracer
1459 1477 - IPython.core.display.DisplayHandle
1460 1478 - IPython.core.display.DisplayHandle.display
1461 1479 - IPython.core.display.DisplayHandle.update
1462 1480 - IPython.core.display.b2a_hex
1463 1481 - IPython.core.display.clear_output
1464 1482 - IPython.core.display.display
1465 1483 - IPython.core.display.publish_display_data
1466 1484 - IPython.core.display.update_display
1467 1485 - IPython.core.excolors.Deprec
1468 1486 - IPython.core.excolors.ExceptionColors
1469 1487 - IPython.core.history.warn
1470 1488 - IPython.core.hooks.late_startup_hook
1471 1489 - IPython.core.hooks.pre_run_code_hook
1472 1490 - IPython.core.hooks.shutdown_hook
1473 1491 - IPython.core.interactiveshell.InteractiveShell.init_deprecation_warnings
1474 1492 - IPython.core.interactiveshell.InteractiveShell.init_readline
1475 1493 - IPython.core.interactiveshell.InteractiveShell.write
1476 1494 - IPython.core.interactiveshell.InteractiveShell.write_err
1477 1495 - IPython.core.interactiveshell.get_default_colors
1478 1496 - IPython.core.interactiveshell.removed_co_newlocals
1479 1497 - IPython.core.magics.execution.ExecutionMagics.profile_missing_notice
1480 1498 - IPython.core.magics.script.PIPE
1481 1499 - IPython.core.prefilter.PrefilterManager.init_transformers
1482 1500 - IPython.core.release.classifiers
1483 1501 - IPython.core.release.description
1484 1502 - IPython.core.release.keywords
1485 1503 - IPython.core.release.long_description
1486 1504 - IPython.core.release.name
1487 1505 - IPython.core.release.platforms
1488 1506 - IPython.core.release.url
1489 1507 - IPython.core.ultratb.VerboseTB.format_records
1490 1508 - IPython.core.ultratb.find_recursion
1491 1509 - IPython.core.ultratb.findsource
1492 1510 - IPython.core.ultratb.fix_frame_records_filenames
1493 1511 - IPython.core.ultratb.inspect_error
1494 1512 - IPython.core.ultratb.is_recursion_error
1495 1513 - IPython.core.ultratb.with_patch_inspect
1496 1514 - IPython.external.__all__
1497 1515 - IPython.external.__builtins__
1498 1516 - IPython.external.__cached__
1499 1517 - IPython.external.__doc__
1500 1518 - IPython.external.__file__
1501 1519 - IPython.external.__loader__
1502 1520 - IPython.external.__name__
1503 1521 - IPython.external.__package__
1504 1522 - IPython.external.__path__
1505 1523 - IPython.external.__spec__
1506 1524 - IPython.kernel.KernelConnectionInfo
1507 1525 - IPython.kernel.__builtins__
1508 1526 - IPython.kernel.__cached__
1509 1527 - IPython.kernel.__warningregistry__
1510 1528 - IPython.kernel.pkg
1511 1529 - IPython.kernel.protocol_version
1512 1530 - IPython.kernel.protocol_version_info
1513 1531 - IPython.kernel.src
1514 1532 - IPython.kernel.version_info
1515 1533 - IPython.kernel.warn
1516 1534 - IPython.lib.backgroundjobs
1517 1535 - IPython.lib.backgroundjobs.BackgroundJobBase
1518 1536 - IPython.lib.backgroundjobs.BackgroundJobBase.run
1519 1537 - IPython.lib.backgroundjobs.BackgroundJobBase.traceback
1520 1538 - IPython.lib.backgroundjobs.BackgroundJobExpr
1521 1539 - IPython.lib.backgroundjobs.BackgroundJobExpr.call
1522 1540 - IPython.lib.backgroundjobs.BackgroundJobFunc
1523 1541 - IPython.lib.backgroundjobs.BackgroundJobFunc.call
1524 1542 - IPython.lib.backgroundjobs.BackgroundJobManager
1525 1543 - IPython.lib.backgroundjobs.BackgroundJobManager.flush
1526 1544 - IPython.lib.backgroundjobs.BackgroundJobManager.new
1527 1545 - IPython.lib.backgroundjobs.BackgroundJobManager.remove
1528 1546 - IPython.lib.backgroundjobs.BackgroundJobManager.result
1529 1547 - IPython.lib.backgroundjobs.BackgroundJobManager.status
1530 1548 - IPython.lib.backgroundjobs.BackgroundJobManager.traceback
1531 1549 - IPython.lib.backgroundjobs.__builtins__
1532 1550 - IPython.lib.backgroundjobs.__cached__
1533 1551 - IPython.lib.backgroundjobs.__doc__
1534 1552 - IPython.lib.backgroundjobs.__file__
1535 1553 - IPython.lib.backgroundjobs.__loader__
1536 1554 - IPython.lib.backgroundjobs.__name__
1537 1555 - IPython.lib.backgroundjobs.__package__
1538 1556 - IPython.lib.backgroundjobs.__spec__
1539 1557 - IPython.lib.kernel.__builtins__
1540 1558 - IPython.lib.kernel.__cached__
1541 1559 - IPython.lib.kernel.__doc__
1542 1560 - IPython.lib.kernel.__file__
1543 1561 - IPython.lib.kernel.__loader__
1544 1562 - IPython.lib.kernel.__name__
1545 1563 - IPython.lib.kernel.__package__
1546 1564 - IPython.lib.kernel.__spec__
1547 1565 - IPython.lib.kernel.__warningregistry__
1548 1566 - IPython.paths.fs_encoding
1549 1567 - IPython.terminal.debugger.DEFAULT_BUFFER
1550 1568 - IPython.terminal.debugger.cursor_in_leading_ws
1551 1569 - IPython.terminal.debugger.emacs_insert_mode
1552 1570 - IPython.terminal.debugger.has_selection
1553 1571 - IPython.terminal.debugger.vi_insert_mode
1554 1572 - IPython.terminal.interactiveshell.DISPLAY_BANNER_DEPRECATED
1555 1573 - IPython.terminal.ipapp.TerminalIPythonApp.parse_command_line
1556 1574 - IPython.testing.test
1557 1575 - IPython.utils.contexts.NoOpContext
1558 1576 - IPython.utils.io.IOStream
1559 1577 - IPython.utils.io.IOStream.close
1560 1578 - IPython.utils.io.IOStream.write
1561 1579 - IPython.utils.io.IOStream.writelines
1562 1580 - IPython.utils.io.__warningregistry__
1563 1581 - IPython.utils.io.atomic_writing
1564 1582 - IPython.utils.io.stderr
1565 1583 - IPython.utils.io.stdin
1566 1584 - IPython.utils.io.stdout
1567 1585 - IPython.utils.io.unicode_std_stream
1568 1586 - IPython.utils.path.get_ipython_cache_dir
1569 1587 - IPython.utils.path.get_ipython_dir
1570 1588 - IPython.utils.path.get_ipython_module_path
1571 1589 - IPython.utils.path.get_ipython_package_dir
1572 1590 - IPython.utils.path.locate_profile
1573 1591 - IPython.utils.path.unquote_filename
1574 1592 - IPython.utils.py3compat.PY2
1575 1593 - IPython.utils.py3compat.PY3
1576 1594 - IPython.utils.py3compat.buffer_to_bytes
1577 1595 - IPython.utils.py3compat.builtin_mod_name
1578 1596 - IPython.utils.py3compat.cast_bytes
1579 1597 - IPython.utils.py3compat.getcwd
1580 1598 - IPython.utils.py3compat.isidentifier
1581 1599 - IPython.utils.py3compat.u_format
1582 1600
1583 1601 The following signatures differ between 7.x and 8.0::
1584 1602
1585 1603 - IPython.core.completer.IPCompleter.unicode_name_matches(self, text)
1586 1604 + IPython.core.completer.IPCompleter.unicode_name_matches(text)
1587 1605
1588 1606 - IPython.core.completer.match_dict_keys(keys, prefix, delims)
1589 1607 + IPython.core.completer.match_dict_keys(keys, prefix, delims, extra_prefix='None')
1590 1608
1591 1609 - IPython.core.interactiveshell.InteractiveShell.object_inspect_mime(self, oname, detail_level=0)
1592 1610 + IPython.core.interactiveshell.InteractiveShell.object_inspect_mime(self, oname, detail_level=0, omit_sections='()')
1593 1611
1594 1612 - IPython.core.interactiveshell.InteractiveShell.set_hook(self, name, hook, priority=50, str_key='None', re_key='None', _warn_deprecated=True)
1595 1613 + IPython.core.interactiveshell.InteractiveShell.set_hook(self, name, hook, priority=50, str_key='None', re_key='None')
1596 1614
1597 1615 - IPython.core.oinspect.Inspector.info(self, obj, oname='', formatter='None', info='None', detail_level=0)
1598 1616 + IPython.core.oinspect.Inspector.info(self, obj, oname='', info='None', detail_level=0)
1599 1617
1600 1618 - IPython.core.oinspect.Inspector.pinfo(self, obj, oname='', formatter='None', info='None', detail_level=0, enable_html_pager=True)
1601 1619 + IPython.core.oinspect.Inspector.pinfo(self, obj, oname='', formatter='None', info='None', detail_level=0, enable_html_pager=True, omit_sections='()')
1602 1620
1603 1621 - IPython.core.profiledir.ProfileDir.copy_config_file(self, config_file, path='None', overwrite=False)
1604 1622 + IPython.core.profiledir.ProfileDir.copy_config_file(self, config_file, path, overwrite=False)
1605 1623
1606 1624 - IPython.core.ultratb.VerboseTB.format_record(self, frame, file, lnum, func, lines, index)
1607 1625 + IPython.core.ultratb.VerboseTB.format_record(self, frame_info)
1608 1626
1609 1627 - IPython.terminal.embed.InteractiveShellEmbed.mainloop(self, local_ns='None', module='None', stack_depth=0, display_banner='None', global_ns='None', compile_flags='None')
1610 1628 + IPython.terminal.embed.InteractiveShellEmbed.mainloop(self, local_ns='None', module='None', stack_depth=0, compile_flags='None')
1611 1629
1612 1630 - IPython.terminal.embed.embed(**kwargs)
1613 1631 + IPython.terminal.embed.embed(*, header='', compile_flags='None', **kwargs)
1614 1632
1615 1633 - IPython.terminal.interactiveshell.TerminalInteractiveShell.interact(self, display_banner='<object object at 0xffffff>')
1616 1634 + IPython.terminal.interactiveshell.TerminalInteractiveShell.interact(self)
1617 1635
1618 1636 - IPython.terminal.interactiveshell.TerminalInteractiveShell.mainloop(self, display_banner='<object object at 0xffffff>')
1619 1637 + IPython.terminal.interactiveshell.TerminalInteractiveShell.mainloop(self)
1620 1638
1621 1639 - IPython.utils.path.get_py_filename(name, force_win32='None')
1622 1640 + IPython.utils.path.get_py_filename(name)
1623 1641
1624 1642 The following are new attributes (that might be inherited)::
1625 1643
1626 1644 + IPython.core.completer.IPCompleter.unicode_names
1627 1645 + IPython.core.debugger.InterruptiblePdb.precmd
1628 1646 + IPython.core.debugger.Pdb.precmd
1629 1647 + IPython.core.ultratb.AutoFormattedTB.has_colors
1630 1648 + IPython.core.ultratb.ColorTB.has_colors
1631 1649 + IPython.core.ultratb.FormattedTB.has_colors
1632 1650 + IPython.core.ultratb.ListTB.has_colors
1633 1651 + IPython.core.ultratb.SyntaxTB.has_colors
1634 1652 + IPython.core.ultratb.TBTools.has_colors
1635 1653 + IPython.core.ultratb.VerboseTB.has_colors
1636 1654 + IPython.terminal.debugger.TerminalPdb.do_interact
1637 1655 + IPython.terminal.debugger.TerminalPdb.precmd
1638 1656
1639 1657 The following attribute/methods have been removed::
1640 1658
1641 1659 - IPython.core.application.BaseIPythonApplication.deprecated_subcommands
1642 1660 - IPython.core.ultratb.AutoFormattedTB.format_records
1643 1661 - IPython.core.ultratb.ColorTB.format_records
1644 1662 - IPython.core.ultratb.FormattedTB.format_records
1645 1663 - IPython.terminal.embed.InteractiveShellEmbed.init_deprecation_warnings
1646 1664 - IPython.terminal.embed.InteractiveShellEmbed.init_readline
1647 1665 - IPython.terminal.embed.InteractiveShellEmbed.write
1648 1666 - IPython.terminal.embed.InteractiveShellEmbed.write_err
1649 1667 - IPython.terminal.interactiveshell.TerminalInteractiveShell.init_deprecation_warnings
1650 1668 - IPython.terminal.interactiveshell.TerminalInteractiveShell.init_readline
1651 1669 - IPython.terminal.interactiveshell.TerminalInteractiveShell.write
1652 1670 - IPython.terminal.interactiveshell.TerminalInteractiveShell.write_err
1653 1671 - IPython.terminal.ipapp.LocateIPythonApp.deprecated_subcommands
1654 1672 - IPython.terminal.ipapp.LocateIPythonApp.initialize_subcommand
1655 1673 - IPython.terminal.ipapp.TerminalIPythonApp.deprecated_subcommands
1656 1674 - IPython.terminal.ipapp.TerminalIPythonApp.initialize_subcommand
General Comments 0
You need to be logged in to leave comments. Login now