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