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