Show More
@@ -1,92 +1,31 | |||||
1 | ===================== |
|
1 | ===================== | |
2 | Development version |
|
2 | Development version | |
3 | ===================== |
|
3 | ===================== | |
4 |
|
4 | |||
5 | This document describes in-flight development work. |
|
5 | This document describes in-flight development work. | |
6 |
|
6 | |||
7 | .. warning:: |
|
7 | .. warning:: | |
8 |
|
8 | |||
9 | Please do not edit this file by hand (doing so will likely cause merge |
|
9 | Please do not edit this file by hand (doing so will likely cause merge | |
10 | conflicts for other Pull Requests). Instead, create a new file in the |
|
10 | conflicts for other Pull Requests). Instead, create a new file in the | |
11 | `docs/source/whatsnew/pr` folder |
|
11 | `docs/source/whatsnew/pr` folder | |
12 |
|
12 | |||
13 |
|
13 | |||
14 |
Released .... ...., 201 |
|
14 | Released .... ...., 2019 | |
15 |
|
15 | |||
16 |
|
16 | |||
17 | Need to be updated: |
|
17 | Need to be updated: | |
18 |
|
18 | |||
19 | .. toctree:: |
|
19 | .. toctree:: | |
20 | :maxdepth: 2 |
|
20 | :maxdepth: 2 | |
21 | :glob: |
|
21 | :glob: | |
22 |
|
22 | |||
23 | pr/* |
|
23 | pr/* | |
24 |
|
24 | |||
25 |
|
||||
26 |
|
||||
27 | Prompt Rendering Performance improvements |
|
|||
28 | ========================================= |
|
|||
29 |
|
||||
30 | Pull Request :ghpull:`11933` introduced an optimisation in the prompt rendering |
|
|||
31 | logic that should decrease the resource usage of IPython when using the |
|
|||
32 | _default_ configuration but could potentially introduce a regression of |
|
|||
33 | functionalities if you are using a custom prompt. |
|
|||
34 |
|
||||
35 | We know assume if you haven't changed the default keybindings that the prompt |
|
|||
36 | **will not change** during the duration of your input – which is for example |
|
|||
37 | not true when using vi insert mode that switches between `[ins]` and `[nor]` |
|
|||
38 | for the current mode. |
|
|||
39 |
|
||||
40 | If you are experiencing any issue let us know. |
|
|||
41 |
|
||||
42 | Code autoformatting |
|
|||
43 | =================== |
|
|||
44 |
|
||||
45 | The IPython terminal can now auto format your code just before entering a new |
|
|||
46 | line or executing a command. To do so use the |
|
|||
47 | ``--TerminalInteractiveShell.autoformatter`` option and set it to ``'black'``; |
|
|||
48 | if black is installed IPython will use black to format your code when possible. |
|
|||
49 |
|
||||
50 | IPython cannot always properly format your code; in particular it will |
|
|||
51 | auto formatting with *black* will only work if: |
|
|||
52 |
|
||||
53 | - Your code does not contains magics or special python syntax. |
|
|||
54 |
|
||||
55 | - There is no code after your cursor. |
|
|||
56 |
|
||||
57 | The Black API is also still in motion; so this may not work with all versions of |
|
|||
58 | black. |
|
|||
59 |
|
||||
60 | It should be possible to register custom reformatter, though the API is till in |
|
|||
61 | flux. |
|
|||
62 |
|
||||
63 | Arbitrary Mimetypes Handing in Terminal |
|
|||
64 | ======================================= |
|
|||
65 |
|
||||
66 | When using IPython terminal it is now possible to register function to handle |
|
|||
67 | arbitrary mimetypes. While rendering non-text based representation was possible in |
|
|||
68 | many jupyter frontend; it was not possible in terminal IPython, as usually |
|
|||
69 | terminal are limited to displaying text. As many terminal these days provide |
|
|||
70 | escape sequences to display non-text; bringing this loved feature to IPython CLI |
|
|||
71 | made a lot of sens. This functionality will not only allow inline images; but |
|
|||
72 | allow opening of external program; for example ``mplayer`` to "display" sound |
|
|||
73 | files. |
|
|||
74 |
|
||||
75 | So far only the hooks necessary for this are in place, but no default mime |
|
|||
76 | renderers added; so inline images will only be available via extensions. We will |
|
|||
77 | progressively enable these features by default in the next few releases, and |
|
|||
78 | contribution is welcomed. |
|
|||
79 |
|
||||
80 | We welcome any feedback on the API. See :ref:`shell_mimerenderer` for more |
|
|||
81 | informations. |
|
|||
82 |
|
||||
83 | This is originally based on work form in :ghpull:`10610` from stephanh42 |
|
|||
84 | started over two years ago, and still a lot need to be done. |
|
|||
85 |
|
||||
86 | .. DO NOT EDIT THIS LINE BEFORE RELEASE. FEATURE INSERTION POINT. |
|
25 | .. DO NOT EDIT THIS LINE BEFORE RELEASE. FEATURE INSERTION POINT. | |
87 |
|
26 | |||
88 |
|
27 | |||
89 | Backwards incompatible changes |
|
28 | Backwards incompatible changes | |
90 | ------------------------------ |
|
29 | ------------------------------ | |
91 |
|
30 | |||
92 | .. DO NOT EDIT THIS LINE BEFORE RELEASE. INCOMPAT INSERTION POINT. No newline at end of file |
|
31 | .. DO NOT EDIT THIS LINE BEFORE RELEASE. INCOMPAT INSERTION POINT. |
@@ -1,634 +1,730 | |||||
1 | ============ |
|
1 | ============ | |
2 | 7.x Series |
|
2 | 7.x Series | |
3 | ============ |
|
3 | ============ | |
4 |
|
4 | |||
|
5 | IPython 7.10.0 | |||
|
6 | ============== | |||
|
7 | ||||
|
8 | IPython 7.10 is the first double digit minor release in the last decade, and | |||
|
9 | first since the release of IPython 1.0, previous double digit minor release was | |||
|
10 | in August 2009. | |||
|
11 | ||||
|
12 | We've been trying to give you regular release on the last Friday of every month | |||
|
13 | for a guaranty of rapid access to bug fixes and new features. | |||
|
14 | ||||
|
15 | Unlike the previous first few releases that have seen only a couple of code | |||
|
16 | changes, 7.10 bring a number of changes, new features and bugfixes. | |||
|
17 | ||||
|
18 | Stop Support for Python 3.5 – Adopt NEP 29 | |||
|
19 | ------------------------------------------ | |||
|
20 | ||||
|
21 | IPython has decided to follow the informational `NEP 29 | |||
|
22 | <https://numpy.org/neps/nep-0029-deprecation_policy.html>`_ which layout a clear | |||
|
23 | policy as to which version of (C)Python and NumPy are supported. | |||
|
24 | ||||
|
25 | We thus dropped support for Python 3.5, and cleaned up a number of code path | |||
|
26 | that were Python-version dependant. If you are on 3.5 or earlier pip should | |||
|
27 | automatically give you the latest compatible version of IPython so you do not | |||
|
28 | need to pin to a given version. | |||
|
29 | ||||
|
30 | ||||
|
31 | Prompt Rendering Performance improvements | |||
|
32 | ----------------------------------------- | |||
|
33 | ||||
|
34 | Pull Request :ghpull:`11933` introduced an optimisation in the prompt rendering | |||
|
35 | logic that should decrease the resource usage of IPython when using the | |||
|
36 | _default_ configuration but could potentially introduce a regression of | |||
|
37 | functionalities if you are using a custom prompt. | |||
|
38 | ||||
|
39 | We know assume if you haven't changed the default keybindings that the prompt | |||
|
40 | **will not change** during the duration of your input – which is for example | |||
|
41 | not true when using vi insert mode that switches between `[ins]` and `[nor]` | |||
|
42 | for the current mode. | |||
|
43 | ||||
|
44 | If you are experiencing any issue let us know. | |||
|
45 | ||||
|
46 | Code autoformatting | |||
|
47 | ------------------- | |||
|
48 | ||||
|
49 | The IPython terminal can now auto format your code just before entering a new | |||
|
50 | line or executing a command. To do so use the | |||
|
51 | ``--TerminalInteractiveShell.autoformatter`` option and set it to ``'black'``; | |||
|
52 | if black is installed IPython will use black to format your code when possible. | |||
|
53 | ||||
|
54 | IPython cannot always properly format your code; in particular it will | |||
|
55 | auto formatting with *black* will only work if: | |||
|
56 | ||||
|
57 | - Your code does not contains magics or special python syntax. | |||
|
58 | ||||
|
59 | - There is no code after your cursor. | |||
|
60 | ||||
|
61 | The Black API is also still in motion; so this may not work with all versions of | |||
|
62 | black. | |||
|
63 | ||||
|
64 | It should be possible to register custom reformatter, though the API is till in | |||
|
65 | flux. | |||
|
66 | ||||
|
67 | Arbitrary Mimetypes Handing in Terminal | |||
|
68 | --------------------------------------- | |||
|
69 | ||||
|
70 | When using IPython terminal it is now possible to register function to handle | |||
|
71 | arbitrary mimetypes. While rendering non-text based representation was possible in | |||
|
72 | many jupyter frontend; it was not possible in terminal IPython, as usually | |||
|
73 | terminal are limited to displaying text. As many terminal these days provide | |||
|
74 | escape sequences to display non-text; bringing this loved feature to IPython CLI | |||
|
75 | made a lot of sens. This functionality will not only allow inline images; but | |||
|
76 | allow opening of external program; for example ``mplayer`` to "display" sound | |||
|
77 | files. | |||
|
78 | ||||
|
79 | So far only the hooks necessary for this are in place, but no default mime | |||
|
80 | renderers added; so inline images will only be available via extensions. We will | |||
|
81 | progressively enable these features by default in the next few releases, and | |||
|
82 | contribution is welcomed. | |||
|
83 | ||||
|
84 | We welcome any feedback on the API. See :ref:`shell_mimerenderer` for more | |||
|
85 | informations. | |||
|
86 | ||||
|
87 | This is originally based on work form in :ghpull:`10610` from stephanh42 | |||
|
88 | started over two years ago, and still a lot need to be done. | |||
|
89 | ||||
|
90 | MISC | |||
|
91 | ---- | |||
|
92 | ||||
|
93 | - Completions can define their own ordering :ghpull:`11855` | |||
|
94 | - Enable Plotting in the same cell than the one that import matplotlib | |||
|
95 | :ghpull:`11916` | |||
|
96 | - Allow to store and restore multiple variables at once :ghpull:`11930` | |||
|
97 | ||||
5 | .. _version 790: |
|
98 | .. _version 790: | |
6 |
|
99 | |||
|
100 | IPython 7.9.0 | |||
|
101 | ============= | |||
|
102 | ||||
7 | IPython 7.9 is a small release with a couple of improvement and bug fixes. |
|
103 | IPython 7.9 is a small release with a couple of improvement and bug fixes. | |
8 |
|
104 | |||
9 | - Xterm terminal title should be restored on exit :ghpull:`11910` |
|
105 | - Xterm terminal title should be restored on exit :ghpull:`11910` | |
10 | - special variables ``_``,``__``, ``___`` are not set anymore when cache size |
|
106 | - special variables ``_``,``__``, ``___`` are not set anymore when cache size | |
11 | is 0 or less. :ghpull:`11877` |
|
107 | is 0 or less. :ghpull:`11877` | |
12 | - Autoreload should have regained some speed by using a new heuristic logic to |
|
108 | - Autoreload should have regained some speed by using a new heuristic logic to | |
13 | find all objects needing reload. This should avoid large objects traversal |
|
109 | find all objects needing reload. This should avoid large objects traversal | |
14 | like pandas dataframes. :ghpull:`11876` |
|
110 | like pandas dataframes. :ghpull:`11876` | |
15 | - Get ready for Python 4. :ghpull:`11874` |
|
111 | - Get ready for Python 4. :ghpull:`11874` | |
16 | - `%env` Magic nonw has euristic to hide potentially sensitive values :ghpull:`11896` |
|
112 | - `%env` Magic nonw has euristic to hide potentially sensitive values :ghpull:`11896` | |
17 |
|
113 | |||
18 | This is a small release despite a number of Pull Request Pending that need to |
|
114 | This is a small release despite a number of Pull Request Pending that need to | |
19 | be reviewed/worked on. Many of the core developers have been busy outside of |
|
115 | be reviewed/worked on. Many of the core developers have been busy outside of | |
20 | IPython/Jupyter and we thanks all contributor for their patience; we'll work on |
|
116 | IPython/Jupyter and we thanks all contributor for their patience; we'll work on | |
21 | these as soon as we have time. |
|
117 | these as soon as we have time. | |
22 |
|
118 | |||
23 |
|
119 | |||
24 | .. _version780: |
|
120 | .. _version780: | |
25 |
|
121 | |||
26 | IPython 7.8.0 |
|
122 | IPython 7.8.0 | |
27 | ============= |
|
123 | ============= | |
28 |
|
124 | |||
29 | IPython 7.8.0 contain a few bugfix and 2 new APIs: |
|
125 | IPython 7.8.0 contain a few bugfix and 2 new APIs: | |
30 |
|
126 | |||
31 | - Enable changing the font color for LaTeX rendering :ghpull:`11840` |
|
127 | - Enable changing the font color for LaTeX rendering :ghpull:`11840` | |
32 | - and Re-Expose some PDB API (see below) |
|
128 | - and Re-Expose some PDB API (see below) | |
33 |
|
129 | |||
34 | Expose Pdb API |
|
130 | Expose Pdb API | |
35 | -------------- |
|
131 | -------------- | |
36 |
|
132 | |||
37 | Expose the built-in ``pdb.Pdb`` API. ``Pdb`` constructor arguments are generically |
|
133 | Expose the built-in ``pdb.Pdb`` API. ``Pdb`` constructor arguments are generically | |
38 | exposed, regardless of python version. |
|
134 | exposed, regardless of python version. | |
39 | Newly exposed arguments: |
|
135 | Newly exposed arguments: | |
40 |
|
136 | |||
41 | - ``skip`` - Python 3.1+ |
|
137 | - ``skip`` - Python 3.1+ | |
42 | - ``nosiginnt`` - Python 3.2+ |
|
138 | - ``nosiginnt`` - Python 3.2+ | |
43 | - ``readrc`` - Python 3.6+ |
|
139 | - ``readrc`` - Python 3.6+ | |
44 |
|
140 | |||
45 | Try it out:: |
|
141 | Try it out:: | |
46 |
|
142 | |||
47 | from IPython.terminal.debugger import TerminalPdb |
|
143 | from IPython.terminal.debugger import TerminalPdb | |
48 | pdb = TerminalPdb(skip=["skipthismodule"]) |
|
144 | pdb = TerminalPdb(skip=["skipthismodule"]) | |
49 |
|
145 | |||
50 |
|
146 | |||
51 | See :ghpull:`11840` |
|
147 | See :ghpull:`11840` | |
52 |
|
148 | |||
53 | .. _version770: |
|
149 | .. _version770: | |
54 |
|
150 | |||
55 | IPython 7.7.0 |
|
151 | IPython 7.7.0 | |
56 | ============= |
|
152 | ============= | |
57 |
|
153 | |||
58 | IPython 7.7.0 contain multiple bug fixes and documentation updates; Here are a |
|
154 | IPython 7.7.0 contain multiple bug fixes and documentation updates; Here are a | |
59 | few of the outstanding issue fixed: |
|
155 | few of the outstanding issue fixed: | |
60 |
|
156 | |||
61 | - Fix a bug introduced in 7.6 where the ``%matplotlib`` magic would fail on |
|
157 | - Fix a bug introduced in 7.6 where the ``%matplotlib`` magic would fail on | |
62 | previously acceptable arguments :ghpull:`11814`. |
|
158 | previously acceptable arguments :ghpull:`11814`. | |
63 | - Fix the manage location on freebsd :ghpull:`11808`. |
|
159 | - Fix the manage location on freebsd :ghpull:`11808`. | |
64 | - Fix error message about aliases after ``%reset`` call in ipykernel |
|
160 | - Fix error message about aliases after ``%reset`` call in ipykernel | |
65 | :ghpull:`11806` |
|
161 | :ghpull:`11806` | |
66 | - Fix Duplication completions in emacs :ghpull:`11803` |
|
162 | - Fix Duplication completions in emacs :ghpull:`11803` | |
67 |
|
163 | |||
68 | We are planning to adopt `NEP29 <https://github.com/numpy/numpy/pull/14086>`_ |
|
164 | We are planning to adopt `NEP29 <https://github.com/numpy/numpy/pull/14086>`_ | |
69 | (still currently in draft) which may make this minor version of IPython the |
|
165 | (still currently in draft) which may make this minor version of IPython the | |
70 | last one to support Python 3.5 and will make the code base more aggressive |
|
166 | last one to support Python 3.5 and will make the code base more aggressive | |
71 | toward removing compatibility with older versions of Python. |
|
167 | toward removing compatibility with older versions of Python. | |
72 |
|
168 | |||
73 | GitHub now support to give only "Triage" permissions to users; if you'd like to |
|
169 | GitHub now support to give only "Triage" permissions to users; if you'd like to | |
74 | help close stale issues and labels issues please reach to us with your GitHub |
|
170 | help close stale issues and labels issues please reach to us with your GitHub | |
75 | Username and we'll add you to the triage team. It is a great way to start |
|
171 | Username and we'll add you to the triage team. It is a great way to start | |
76 | contributing and a path toward getting commit rights. |
|
172 | contributing and a path toward getting commit rights. | |
77 |
|
173 | |||
78 | .. _version761: |
|
174 | .. _version761: | |
79 |
|
175 | |||
80 | IPython 7.6.1 |
|
176 | IPython 7.6.1 | |
81 | ============= |
|
177 | ============= | |
82 |
|
178 | |||
83 | IPython 7.6.1 contain a critical bugfix in the ``%timeit`` magic, which would |
|
179 | IPython 7.6.1 contain a critical bugfix in the ``%timeit`` magic, which would | |
84 | crash on some inputs as a side effect of :ghpull:`11716`. See :ghpull:`11812` |
|
180 | crash on some inputs as a side effect of :ghpull:`11716`. See :ghpull:`11812` | |
85 |
|
181 | |||
86 |
|
182 | |||
87 | .. _whatsnew760: |
|
183 | .. _whatsnew760: | |
88 |
|
184 | |||
89 | IPython 7.6.0 |
|
185 | IPython 7.6.0 | |
90 | ============= |
|
186 | ============= | |
91 |
|
187 | |||
92 | IPython 7.6.0 contains a couple of bug fixes and number of small features |
|
188 | IPython 7.6.0 contains a couple of bug fixes and number of small features | |
93 | additions as well as some compatibility with the current development version of |
|
189 | additions as well as some compatibility with the current development version of | |
94 | Python 3.8. |
|
190 | Python 3.8. | |
95 |
|
191 | |||
96 | - Add a ``-l`` option to :magic:`psearch` to list the available search |
|
192 | - Add a ``-l`` option to :magic:`psearch` to list the available search | |
97 | types. :ghpull:`11672` |
|
193 | types. :ghpull:`11672` | |
98 | - Support ``PathLike`` for ``DisplayObject`` and ``Image``. :ghpull:`11764` |
|
194 | - Support ``PathLike`` for ``DisplayObject`` and ``Image``. :ghpull:`11764` | |
99 | - Configurability of timeout in the test suite for slow platforms. |
|
195 | - Configurability of timeout in the test suite for slow platforms. | |
100 | :ghpull:`11756` |
|
196 | :ghpull:`11756` | |
101 | - Accept any casing for matplotlib backend. :ghpull:`121748` |
|
197 | - Accept any casing for matplotlib backend. :ghpull:`121748` | |
102 | - Properly skip test that requires numpy to be installed :ghpull:`11723` |
|
198 | - Properly skip test that requires numpy to be installed :ghpull:`11723` | |
103 | - More support for Python 3.8 and positional only arguments (pep570) |
|
199 | - More support for Python 3.8 and positional only arguments (pep570) | |
104 | :ghpull:`11720` |
|
200 | :ghpull:`11720` | |
105 | - Unicode names for the completion are loaded lazily on first use which |
|
201 | - Unicode names for the completion are loaded lazily on first use which | |
106 | should decrease startup time. :ghpull:`11693` |
|
202 | should decrease startup time. :ghpull:`11693` | |
107 | - Autoreload now update the types of reloaded objects; this for example allow |
|
203 | - Autoreload now update the types of reloaded objects; this for example allow | |
108 | pickling of reloaded objects. :ghpull:`11644` |
|
204 | pickling of reloaded objects. :ghpull:`11644` | |
109 | - Fix a bug where ``%%time`` magic would suppress cell output. :ghpull:`11716` |
|
205 | - Fix a bug where ``%%time`` magic would suppress cell output. :ghpull:`11716` | |
110 |
|
206 | |||
111 |
|
207 | |||
112 | Prepare migration to pytest (instead of nose) for testing |
|
208 | Prepare migration to pytest (instead of nose) for testing | |
113 | --------------------------------------------------------- |
|
209 | --------------------------------------------------------- | |
114 |
|
210 | |||
115 | Most of the work between 7.5 and 7.6 was to prepare the migration from our |
|
211 | Most of the work between 7.5 and 7.6 was to prepare the migration from our | |
116 | testing framework to pytest. Most of the test suite should now work by simply |
|
212 | testing framework to pytest. Most of the test suite should now work by simply | |
117 | issuing ``pytest`` from the root of the repository. |
|
213 | issuing ``pytest`` from the root of the repository. | |
118 |
|
214 | |||
119 | The migration to pytest is just at its beginning. Many of our test still rely |
|
215 | The migration to pytest is just at its beginning. Many of our test still rely | |
120 | on IPython-specific plugins for nose using pytest (doctest using IPython syntax |
|
216 | on IPython-specific plugins for nose using pytest (doctest using IPython syntax | |
121 | is one example of this where test appear as "passing", while no code has been |
|
217 | is one example of this where test appear as "passing", while no code has been | |
122 | ran). Many test also need to be updated like ``yield-test`` to be properly |
|
218 | ran). Many test also need to be updated like ``yield-test`` to be properly | |
123 | parametrized tests. |
|
219 | parametrized tests. | |
124 |
|
220 | |||
125 | Migration to pytest allowed me to discover a number of issues in our test |
|
221 | Migration to pytest allowed me to discover a number of issues in our test | |
126 | suite; which was hiding a number of subtle issues – or not actually running |
|
222 | suite; which was hiding a number of subtle issues – or not actually running | |
127 | some of the tests in our test suite – I have thus corrected many of those; like |
|
223 | some of the tests in our test suite – I have thus corrected many of those; like | |
128 | improperly closed resources; or used of deprecated features. I also made use of |
|
224 | improperly closed resources; or used of deprecated features. I also made use of | |
129 | the ``pytest --durations=...`` to find some of our slowest test and speed them |
|
225 | the ``pytest --durations=...`` to find some of our slowest test and speed them | |
130 | up (our test suite can now be up to 10% faster). Pytest as also a variety of |
|
226 | up (our test suite can now be up to 10% faster). Pytest as also a variety of | |
131 | plugins and flags which will make the code quality of IPython and the testing |
|
227 | plugins and flags which will make the code quality of IPython and the testing | |
132 | experience better. |
|
228 | experience better. | |
133 |
|
229 | |||
134 | Misc |
|
230 | Misc | |
135 | ---- |
|
231 | ---- | |
136 |
|
232 | |||
137 | We skipped the release of 7.6 at the end of May, but will attempt to get back |
|
233 | We skipped the release of 7.6 at the end of May, but will attempt to get back | |
138 | on schedule. We are starting to think about making introducing backward |
|
234 | on schedule. We are starting to think about making introducing backward | |
139 | incompatible change and start the 8.0 series. |
|
235 | incompatible change and start the 8.0 series. | |
140 |
|
236 | |||
141 | Special Thanks to Gabriel (@gpotter2 on GitHub), who among other took care many |
|
237 | Special Thanks to Gabriel (@gpotter2 on GitHub), who among other took care many | |
142 | of the remaining task for 7.4 and 7.5, like updating the website. |
|
238 | of the remaining task for 7.4 and 7.5, like updating the website. | |
143 |
|
239 | |||
144 | .. _whatsnew750: |
|
240 | .. _whatsnew750: | |
145 |
|
241 | |||
146 | IPython 7.5.0 |
|
242 | IPython 7.5.0 | |
147 | ============= |
|
243 | ============= | |
148 |
|
244 | |||
149 | IPython 7.5.0 consist mostly of bug-fixes, and documentation updates, with one |
|
245 | IPython 7.5.0 consist mostly of bug-fixes, and documentation updates, with one | |
150 | minor new feature. The `Audio` display element can now be assigned an element |
|
246 | minor new feature. The `Audio` display element can now be assigned an element | |
151 | id when displayed in browser. See :ghpull:`11670` |
|
247 | id when displayed in browser. See :ghpull:`11670` | |
152 |
|
248 | |||
153 | The major outstanding bug fix correct a change of behavior that was introduce |
|
249 | The major outstanding bug fix correct a change of behavior that was introduce | |
154 | in 7.4.0 where some cell magics would not be able to access or modify global |
|
250 | in 7.4.0 where some cell magics would not be able to access or modify global | |
155 | scope when using the ``@needs_local_scope`` decorator. This was typically |
|
251 | scope when using the ``@needs_local_scope`` decorator. This was typically | |
156 | encountered with the ``%%time`` and ``%%timeit`` magics. See :ghissue:`11659` |
|
252 | encountered with the ``%%time`` and ``%%timeit`` magics. See :ghissue:`11659` | |
157 | and :ghpull:`11698`. |
|
253 | and :ghpull:`11698`. | |
158 |
|
254 | |||
159 | .. _whatsnew740: |
|
255 | .. _whatsnew740: | |
160 |
|
256 | |||
161 | IPython 7.4.0 |
|
257 | IPython 7.4.0 | |
162 | ============= |
|
258 | ============= | |
163 |
|
259 | |||
164 | Unicode name completions |
|
260 | Unicode name completions | |
165 | ------------------------ |
|
261 | ------------------------ | |
166 |
|
262 | |||
167 | Previously, we provided completion for a unicode name with its relative symbol. |
|
263 | Previously, we provided completion for a unicode name with its relative symbol. | |
168 | With this, now IPython provides complete suggestions to unicode name symbols. |
|
264 | With this, now IPython provides complete suggestions to unicode name symbols. | |
169 |
|
265 | |||
170 | As on the PR, if user types ``\LAT<tab>``, IPython provides a list of |
|
266 | As on the PR, if user types ``\LAT<tab>``, IPython provides a list of | |
171 | possible completions. In this case, it would be something like:: |
|
267 | possible completions. In this case, it would be something like:: | |
172 |
|
268 | |||
173 | 'LATIN CAPITAL LETTER A', |
|
269 | 'LATIN CAPITAL LETTER A', | |
174 | 'LATIN CAPITAL LETTER B', |
|
270 | 'LATIN CAPITAL LETTER B', | |
175 | 'LATIN CAPITAL LETTER C', |
|
271 | 'LATIN CAPITAL LETTER C', | |
176 | 'LATIN CAPITAL LETTER D', |
|
272 | 'LATIN CAPITAL LETTER D', | |
177 | .... |
|
273 | .... | |
178 |
|
274 | |||
179 | This help to type unicode character that do not have short latex aliases, and |
|
275 | This help to type unicode character that do not have short latex aliases, and | |
180 | have long unicode names. for example ``Ͱ``, ``\GREEK CAPITAL LETTER HETA``. |
|
276 | have long unicode names. for example ``Ͱ``, ``\GREEK CAPITAL LETTER HETA``. | |
181 |
|
277 | |||
182 | This feature was contributed by Luciana Marques :ghpull:`11583`. |
|
278 | This feature was contributed by Luciana Marques :ghpull:`11583`. | |
183 |
|
279 | |||
184 | Make audio normalization optional |
|
280 | Make audio normalization optional | |
185 | --------------------------------- |
|
281 | --------------------------------- | |
186 |
|
282 | |||
187 | Added 'normalize' argument to `IPython.display.Audio`. This argument applies |
|
283 | Added 'normalize' argument to `IPython.display.Audio`. This argument applies | |
188 | when audio data is given as an array of samples. The default of `normalize=True` |
|
284 | when audio data is given as an array of samples. The default of `normalize=True` | |
189 | preserves prior behavior of normalizing the audio to the maximum possible range. |
|
285 | preserves prior behavior of normalizing the audio to the maximum possible range. | |
190 | Setting to `False` disables normalization. |
|
286 | Setting to `False` disables normalization. | |
191 |
|
287 | |||
192 |
|
288 | |||
193 | Miscellaneous |
|
289 | Miscellaneous | |
194 | ------------- |
|
290 | ------------- | |
195 |
|
291 | |||
196 | - Fix improper acceptation of ``return`` outside of functions. :ghpull:`11641`. |
|
292 | - Fix improper acceptation of ``return`` outside of functions. :ghpull:`11641`. | |
197 | - Fixed PyQt 5.11 backwards incompatibility causing sip import failure. |
|
293 | - Fixed PyQt 5.11 backwards incompatibility causing sip import failure. | |
198 | :ghpull:`11613`. |
|
294 | :ghpull:`11613`. | |
199 | - Fix Bug where ``type?`` would crash IPython. :ghpull:`1608`. |
|
295 | - Fix Bug where ``type?`` would crash IPython. :ghpull:`1608`. | |
200 | - Allow to apply ``@needs_local_scope`` to cell magics for convenience. |
|
296 | - Allow to apply ``@needs_local_scope`` to cell magics for convenience. | |
201 | :ghpull:`11542`. |
|
297 | :ghpull:`11542`. | |
202 |
|
298 | |||
203 | .. _whatsnew730: |
|
299 | .. _whatsnew730: | |
204 |
|
300 | |||
205 | IPython 7.3.0 |
|
301 | IPython 7.3.0 | |
206 | ============= |
|
302 | ============= | |
207 |
|
303 | |||
208 | .. _whatsnew720: |
|
304 | .. _whatsnew720: | |
209 |
|
305 | |||
210 | IPython 7.3.0 bring several bug fixes and small improvements that you will |
|
306 | IPython 7.3.0 bring several bug fixes and small improvements that you will | |
211 | described bellow. |
|
307 | described bellow. | |
212 |
|
308 | |||
213 | The biggest change to this release is the implementation of the ``%conda`` and |
|
309 | The biggest change to this release is the implementation of the ``%conda`` and | |
214 | ``%pip`` magics, that will attempt to install packages in the **current |
|
310 | ``%pip`` magics, that will attempt to install packages in the **current | |
215 | environment**. You may still need to restart your interpreter or kernel for the |
|
311 | environment**. You may still need to restart your interpreter or kernel for the | |
216 | change to be taken into account, but it should simplify installation of packages |
|
312 | change to be taken into account, but it should simplify installation of packages | |
217 | into remote environment. Installing using pip/conda from the command line is |
|
313 | into remote environment. Installing using pip/conda from the command line is | |
218 | still the prefer method. |
|
314 | still the prefer method. | |
219 |
|
315 | |||
220 | The ``%pip`` magic was already present, but was only printing a warning; now it |
|
316 | The ``%pip`` magic was already present, but was only printing a warning; now it | |
221 | will actually forward commands to pip. |
|
317 | will actually forward commands to pip. | |
222 |
|
318 | |||
223 | Misc bug fixes and improvements: |
|
319 | Misc bug fixes and improvements: | |
224 |
|
320 | |||
225 | - Compatibility with Python 3.8. |
|
321 | - Compatibility with Python 3.8. | |
226 | - Do not expand shell variable in execution magics, and added the |
|
322 | - Do not expand shell variable in execution magics, and added the | |
227 | ``no_var_expand`` decorator for magic requiring a similar functionality |
|
323 | ``no_var_expand`` decorator for magic requiring a similar functionality | |
228 | :ghpull:`11516` |
|
324 | :ghpull:`11516` | |
229 | - Add ``%pip`` and ``%conda`` magic :ghpull:`11524` |
|
325 | - Add ``%pip`` and ``%conda`` magic :ghpull:`11524` | |
230 | - Re-initialize posix aliases after a ``%reset`` :ghpull:`11528` |
|
326 | - Re-initialize posix aliases after a ``%reset`` :ghpull:`11528` | |
231 | - Allow the IPython command line to run ``*.ipynb`` files :ghpull:`11529` |
|
327 | - Allow the IPython command line to run ``*.ipynb`` files :ghpull:`11529` | |
232 |
|
328 | |||
233 | IPython 7.2.0 |
|
329 | IPython 7.2.0 | |
234 | ============= |
|
330 | ============= | |
235 |
|
331 | |||
236 | IPython 7.2.0 brings minor bugfixes, improvements, and new configuration options: |
|
332 | IPython 7.2.0 brings minor bugfixes, improvements, and new configuration options: | |
237 |
|
333 | |||
238 | - Fix a bug preventing PySide2 GUI integration from working :ghpull:`11464` |
|
334 | - Fix a bug preventing PySide2 GUI integration from working :ghpull:`11464` | |
239 | - Run CI on Mac OS ! :ghpull:`11471` |
|
335 | - Run CI on Mac OS ! :ghpull:`11471` | |
240 | - Fix IPython "Demo" mode. :ghpull:`11498` |
|
336 | - Fix IPython "Demo" mode. :ghpull:`11498` | |
241 | - Fix ``%run`` magic with path in name :ghpull:`11499` |
|
337 | - Fix ``%run`` magic with path in name :ghpull:`11499` | |
242 | - Fix: add CWD to sys.path *after* stdlib :ghpull:`11502` |
|
338 | - Fix: add CWD to sys.path *after* stdlib :ghpull:`11502` | |
243 | - Better rendering of signatures, especially long ones. :ghpull:`11505` |
|
339 | - Better rendering of signatures, especially long ones. :ghpull:`11505` | |
244 | - Re-enable jedi by default if it's installed :ghpull:`11506` |
|
340 | - Re-enable jedi by default if it's installed :ghpull:`11506` | |
245 | - Add New ``minimal`` exception reporting mode (useful for educational purpose). See :ghpull:`11509` |
|
341 | - Add New ``minimal`` exception reporting mode (useful for educational purpose). See :ghpull:`11509` | |
246 |
|
342 | |||
247 |
|
343 | |||
248 | Added ability to show subclasses when using pinfo and other utilities |
|
344 | Added ability to show subclasses when using pinfo and other utilities | |
249 | --------------------------------------------------------------------- |
|
345 | --------------------------------------------------------------------- | |
250 |
|
346 | |||
251 | When using ``?``/``??`` on a class, IPython will now list the first 10 subclasses. |
|
347 | When using ``?``/``??`` on a class, IPython will now list the first 10 subclasses. | |
252 |
|
348 | |||
253 | Special Thanks to Chris Mentzel of the Moore Foundation for this feature. Chris |
|
349 | Special Thanks to Chris Mentzel of the Moore Foundation for this feature. Chris | |
254 | is one of the people who played a critical role in IPython/Jupyter getting |
|
350 | is one of the people who played a critical role in IPython/Jupyter getting | |
255 | funding. |
|
351 | funding. | |
256 |
|
352 | |||
257 | We are grateful for all the help Chris has given us over the years, |
|
353 | We are grateful for all the help Chris has given us over the years, | |
258 | and we're now proud to have code contributed by Chris in IPython. |
|
354 | and we're now proud to have code contributed by Chris in IPython. | |
259 |
|
355 | |||
260 | OSMagics.cd_force_quiet configuration option |
|
356 | OSMagics.cd_force_quiet configuration option | |
261 | -------------------------------------------- |
|
357 | -------------------------------------------- | |
262 |
|
358 | |||
263 | You can set this option to force the %cd magic to behave as if ``-q`` was passed: |
|
359 | You can set this option to force the %cd magic to behave as if ``-q`` was passed: | |
264 | :: |
|
360 | :: | |
265 |
|
361 | |||
266 | In [1]: cd / |
|
362 | In [1]: cd / | |
267 | / |
|
363 | / | |
268 |
|
364 | |||
269 | In [2]: %config OSMagics.cd_force_quiet = True |
|
365 | In [2]: %config OSMagics.cd_force_quiet = True | |
270 |
|
366 | |||
271 | In [3]: cd /tmp |
|
367 | In [3]: cd /tmp | |
272 |
|
368 | |||
273 | In [4]: |
|
369 | In [4]: | |
274 |
|
370 | |||
275 | See :ghpull:`11491` |
|
371 | See :ghpull:`11491` | |
276 |
|
372 | |||
277 | In vi editing mode, whether the prompt includes the current vi mode can now be configured |
|
373 | In vi editing mode, whether the prompt includes the current vi mode can now be configured | |
278 | ----------------------------------------------------------------------------------------- |
|
374 | ----------------------------------------------------------------------------------------- | |
279 |
|
375 | |||
280 | Set the ``TerminalInteractiveShell.prompt_includes_vi_mode`` to a boolean value |
|
376 | Set the ``TerminalInteractiveShell.prompt_includes_vi_mode`` to a boolean value | |
281 | (default: True) to control this feature. See :ghpull:`11492` |
|
377 | (default: True) to control this feature. See :ghpull:`11492` | |
282 |
|
378 | |||
283 | .. _whatsnew710: |
|
379 | .. _whatsnew710: | |
284 |
|
380 | |||
285 | IPython 7.1.0 |
|
381 | IPython 7.1.0 | |
286 | ============= |
|
382 | ============= | |
287 |
|
383 | |||
288 | IPython 7.1.0 is the first minor release after 7.0.0 and mostly brings fixes to |
|
384 | IPython 7.1.0 is the first minor release after 7.0.0 and mostly brings fixes to | |
289 | new features, internal refactoring, and fixes for regressions that happened during the 6.x->7.x |
|
385 | new features, internal refactoring, and fixes for regressions that happened during the 6.x->7.x | |
290 | transition. It also brings **Compatibility with Python 3.7.1**, as we're |
|
386 | transition. It also brings **Compatibility with Python 3.7.1**, as we're | |
291 | unwillingly relying on a bug in CPython. |
|
387 | unwillingly relying on a bug in CPython. | |
292 |
|
388 | |||
293 | New Core Dev: |
|
389 | New Core Dev: | |
294 |
|
390 | |||
295 | - We welcome Jonathan Slenders to the commiters. Jonathan has done a fantastic |
|
391 | - We welcome Jonathan Slenders to the commiters. Jonathan has done a fantastic | |
296 | work on prompt_toolkit, and we'd like to recognise his impact by giving him |
|
392 | work on prompt_toolkit, and we'd like to recognise his impact by giving him | |
297 | commit rights. :ghissue:`11397` |
|
393 | commit rights. :ghissue:`11397` | |
298 |
|
394 | |||
299 | Notable Changes |
|
395 | Notable Changes | |
300 |
|
396 | |||
301 | - Major update of "latex to unicode" tab completion map (see below) |
|
397 | - Major update of "latex to unicode" tab completion map (see below) | |
302 |
|
398 | |||
303 | Notable New Features: |
|
399 | Notable New Features: | |
304 |
|
400 | |||
305 | - Restore functionality and documentation of the **sphinx directive**, which |
|
401 | - Restore functionality and documentation of the **sphinx directive**, which | |
306 | is now stricter (fail on error by daefault), has new configuration options, |
|
402 | is now stricter (fail on error by daefault), has new configuration options, | |
307 | has a brand new documentation page :ref:`ipython_directive` (which needs |
|
403 | has a brand new documentation page :ref:`ipython_directive` (which needs | |
308 | some cleanup). It is also now *tested* so we hope to have less regressions. |
|
404 | some cleanup). It is also now *tested* so we hope to have less regressions. | |
309 | :ghpull:`11402` |
|
405 | :ghpull:`11402` | |
310 |
|
406 | |||
311 | - ``IPython.display.Video`` now supports ``width`` and ``height`` arguments, |
|
407 | - ``IPython.display.Video`` now supports ``width`` and ``height`` arguments, | |
312 | allowing a custom width and height to be set instead of using the video's |
|
408 | allowing a custom width and height to be set instead of using the video's | |
313 | width and height. :ghpull:`11353` |
|
409 | width and height. :ghpull:`11353` | |
314 |
|
410 | |||
315 | - Warn when using ``HTML('<iframe>')`` instead of ``IFrame`` :ghpull:`11350` |
|
411 | - Warn when using ``HTML('<iframe>')`` instead of ``IFrame`` :ghpull:`11350` | |
316 |
|
412 | |||
317 | - Allow Dynamic switching of editing mode between vi/emacs and show |
|
413 | - Allow Dynamic switching of editing mode between vi/emacs and show | |
318 | normal/input mode in prompt when using vi. :ghpull:`11390`. Use ``%config |
|
414 | normal/input mode in prompt when using vi. :ghpull:`11390`. Use ``%config | |
319 | TerminalInteractiveShell.editing_mode = 'vi'`` or ``%config |
|
415 | TerminalInteractiveShell.editing_mode = 'vi'`` or ``%config | |
320 | TerminalInteractiveShell.editing_mode = 'emacs'`` to dynamically switch |
|
416 | TerminalInteractiveShell.editing_mode = 'emacs'`` to dynamically switch | |
321 | between modes. |
|
417 | between modes. | |
322 |
|
418 | |||
323 |
|
419 | |||
324 | Notable Fixes: |
|
420 | Notable Fixes: | |
325 |
|
421 | |||
326 | - Fix entering of **multi-line blocks in terminal** IPython, and various |
|
422 | - Fix entering of **multi-line blocks in terminal** IPython, and various | |
327 | crashes in the new input transformation machinery :ghpull:`11354`, |
|
423 | crashes in the new input transformation machinery :ghpull:`11354`, | |
328 | :ghpull:`11356`, :ghpull:`11358`. These also fix a **Compatibility bug |
|
424 | :ghpull:`11356`, :ghpull:`11358`. These also fix a **Compatibility bug | |
329 | with Python 3.7.1**. |
|
425 | with Python 3.7.1**. | |
330 |
|
426 | |||
331 | - Fix moving through generator stack in ipdb :ghpull:`11266` |
|
427 | - Fix moving through generator stack in ipdb :ghpull:`11266` | |
332 |
|
428 | |||
333 | - %Magic command arguments now support quoting. :ghpull:`11330` |
|
429 | - %Magic command arguments now support quoting. :ghpull:`11330` | |
334 |
|
430 | |||
335 | - Re-add ``rprint`` and ``rprinte`` aliases. :ghpull:`11331` |
|
431 | - Re-add ``rprint`` and ``rprinte`` aliases. :ghpull:`11331` | |
336 |
|
432 | |||
337 | - Remove implicit dependency on ``ipython_genutils`` :ghpull:`11317` |
|
433 | - Remove implicit dependency on ``ipython_genutils`` :ghpull:`11317` | |
338 |
|
434 | |||
339 | - Make ``nonlocal`` raise ``SyntaxError`` instead of silently failing in async |
|
435 | - Make ``nonlocal`` raise ``SyntaxError`` instead of silently failing in async | |
340 | mode. :ghpull:`11382` |
|
436 | mode. :ghpull:`11382` | |
341 |
|
437 | |||
342 | - Fix mishandling of magics and ``= !`` assignment just after a dedent in |
|
438 | - Fix mishandling of magics and ``= !`` assignment just after a dedent in | |
343 | nested code blocks :ghpull:`11418` |
|
439 | nested code blocks :ghpull:`11418` | |
344 |
|
440 | |||
345 | - Fix instructions for custom shortcuts :ghpull:`11426` |
|
441 | - Fix instructions for custom shortcuts :ghpull:`11426` | |
346 |
|
442 | |||
347 |
|
443 | |||
348 | Notable Internals improvements: |
|
444 | Notable Internals improvements: | |
349 |
|
445 | |||
350 | - Use of ``os.scandir`` (Python 3 only) to speed up some file system operations. |
|
446 | - Use of ``os.scandir`` (Python 3 only) to speed up some file system operations. | |
351 | :ghpull:`11365` |
|
447 | :ghpull:`11365` | |
352 |
|
448 | |||
353 | - use ``perf_counter`` instead of ``clock`` for more precise |
|
449 | - use ``perf_counter`` instead of ``clock`` for more precise | |
354 | timing results with ``%time`` :ghpull:`11376` |
|
450 | timing results with ``%time`` :ghpull:`11376` | |
355 |
|
451 | |||
356 | Many thanks to all the contributors and in particular to ``bartskowron`` and |
|
452 | Many thanks to all the contributors and in particular to ``bartskowron`` and | |
357 | ``tonyfast`` who handled some pretty complicated bugs in the input machinery. We |
|
453 | ``tonyfast`` who handled some pretty complicated bugs in the input machinery. We | |
358 | had a number of first time contributors and maybe hacktoberfest participants that |
|
454 | had a number of first time contributors and maybe hacktoberfest participants that | |
359 | made significant contributions and helped us free some time to focus on more |
|
455 | made significant contributions and helped us free some time to focus on more | |
360 | complicated bugs. |
|
456 | complicated bugs. | |
361 |
|
457 | |||
362 | You |
|
458 | You | |
363 | can see all the closed issues and Merged PR, new features and fixes `here |
|
459 | can see all the closed issues and Merged PR, new features and fixes `here | |
364 | <https://github.com/ipython/ipython/issues?utf8=%E2%9C%93&q=+is%3Aclosed+milestone%3A7.1+>`_. |
|
460 | <https://github.com/ipython/ipython/issues?utf8=%E2%9C%93&q=+is%3Aclosed+milestone%3A7.1+>`_. | |
365 |
|
461 | |||
366 | Unicode Completion update |
|
462 | Unicode Completion update | |
367 | ------------------------- |
|
463 | ------------------------- | |
368 |
|
464 | |||
369 | In IPython 7.1 the Unicode completion map has been updated and synchronized with |
|
465 | In IPython 7.1 the Unicode completion map has been updated and synchronized with | |
370 | the Julia language. |
|
466 | the Julia language. | |
371 |
|
467 | |||
372 | Added and removed character characters: |
|
468 | Added and removed character characters: | |
373 |
|
469 | |||
374 | ``\jmath`` (``ȷ``), ``\\underleftrightarrow`` (U+034D, combining) have been |
|
470 | ``\jmath`` (``ȷ``), ``\\underleftrightarrow`` (U+034D, combining) have been | |
375 | added, while ``\\textasciicaron`` have been removed |
|
471 | added, while ``\\textasciicaron`` have been removed | |
376 |
|
472 | |||
377 | Some sequences have seen their prefix removed: |
|
473 | Some sequences have seen their prefix removed: | |
378 |
|
474 | |||
379 | - 6 characters ``\text...<tab>`` should now be inputed with ``\...<tab>`` directly, |
|
475 | - 6 characters ``\text...<tab>`` should now be inputed with ``\...<tab>`` directly, | |
380 | - 45 characters ``\Elz...<tab>`` should now be inputed with ``\...<tab>`` directly, |
|
476 | - 45 characters ``\Elz...<tab>`` should now be inputed with ``\...<tab>`` directly, | |
381 | - 65 characters ``\B...<tab>`` should now be inputed with ``\...<tab>`` directly, |
|
477 | - 65 characters ``\B...<tab>`` should now be inputed with ``\...<tab>`` directly, | |
382 | - 450 characters ``\m...<tab>`` should now be inputed with ``\...<tab>`` directly, |
|
478 | - 450 characters ``\m...<tab>`` should now be inputed with ``\...<tab>`` directly, | |
383 |
|
479 | |||
384 | Some sequences have seen their prefix shortened: |
|
480 | Some sequences have seen their prefix shortened: | |
385 |
|
481 | |||
386 | - 5 characters ``\mitBbb...<tab>`` should now be inputed with ``\bbi...<tab>`` directly, |
|
482 | - 5 characters ``\mitBbb...<tab>`` should now be inputed with ``\bbi...<tab>`` directly, | |
387 | - 52 characters ``\mit...<tab>`` should now be inputed with ``\i...<tab>`` directly, |
|
483 | - 52 characters ``\mit...<tab>`` should now be inputed with ``\i...<tab>`` directly, | |
388 | - 216 characters ``\mbfit...<tab>`` should now be inputed with ``\bi...<tab>`` directly, |
|
484 | - 216 characters ``\mbfit...<tab>`` should now be inputed with ``\bi...<tab>`` directly, | |
389 | - 222 characters ``\mbf...<tab>`` should now be inputed with ``\b...<tab>`` directly, |
|
485 | - 222 characters ``\mbf...<tab>`` should now be inputed with ``\b...<tab>`` directly, | |
390 |
|
486 | |||
391 | A couple of characters had their sequence simplified: |
|
487 | A couple of characters had their sequence simplified: | |
392 |
|
488 | |||
393 | - ``ð``, type ``\dh<tab>``, instead of ``\eth<tab>`` |
|
489 | - ``ð``, type ``\dh<tab>``, instead of ``\eth<tab>`` | |
394 | - ``ħ``, type ``\hbar<tab>``, instead of ``\Elzxh<tab>`` |
|
490 | - ``ħ``, type ``\hbar<tab>``, instead of ``\Elzxh<tab>`` | |
395 | - ``ɸ``, type ``\ltphi<tab>``, instead of ``\textphi<tab>`` |
|
491 | - ``ɸ``, type ``\ltphi<tab>``, instead of ``\textphi<tab>`` | |
396 | - ``ϴ``, type ``\varTheta<tab>``, instead of ``\textTheta<tab>`` |
|
492 | - ``ϴ``, type ``\varTheta<tab>``, instead of ``\textTheta<tab>`` | |
397 | - ``ℇ``, type ``\eulermascheroni<tab>``, instead of ``\Eulerconst<tab>`` |
|
493 | - ``ℇ``, type ``\eulermascheroni<tab>``, instead of ``\Eulerconst<tab>`` | |
398 | - ``ℎ``, type ``\planck<tab>``, instead of ``\Planckconst<tab>`` |
|
494 | - ``ℎ``, type ``\planck<tab>``, instead of ``\Planckconst<tab>`` | |
399 |
|
495 | |||
400 | - U+0336 (COMBINING LONG STROKE OVERLAY), type ``\strike<tab>``, instead of ``\Elzbar<tab>``. |
|
496 | - U+0336 (COMBINING LONG STROKE OVERLAY), type ``\strike<tab>``, instead of ``\Elzbar<tab>``. | |
401 |
|
497 | |||
402 | A couple of sequences have been updated: |
|
498 | A couple of sequences have been updated: | |
403 |
|
499 | |||
404 | - ``\varepsilon`` now gives ``ɛ`` (GREEK SMALL LETTER EPSILON) instead of ``ε`` (GREEK LUNATE EPSILON SYMBOL), |
|
500 | - ``\varepsilon`` now gives ``ɛ`` (GREEK SMALL LETTER EPSILON) instead of ``ε`` (GREEK LUNATE EPSILON SYMBOL), | |
405 | - ``\underbar`` now gives U+0331 (COMBINING MACRON BELOW) instead of U+0332 (COMBINING LOW LINE). |
|
501 | - ``\underbar`` now gives U+0331 (COMBINING MACRON BELOW) instead of U+0332 (COMBINING LOW LINE). | |
406 |
|
502 | |||
407 |
|
503 | |||
408 | .. _whatsnew700: |
|
504 | .. _whatsnew700: | |
409 |
|
505 | |||
410 | IPython 7.0.0 |
|
506 | IPython 7.0.0 | |
411 | ============= |
|
507 | ============= | |
412 |
|
508 | |||
413 | Released Thursday September 27th, 2018 |
|
509 | Released Thursday September 27th, 2018 | |
414 |
|
510 | |||
415 | IPython 7 includes major feature improvements. |
|
511 | IPython 7 includes major feature improvements. | |
416 | This is also the second major version of IPython to support only |
|
512 | This is also the second major version of IPython to support only | |
417 | Python 3 – starting at Python 3.4. Python 2 is still community-supported |
|
513 | Python 3 – starting at Python 3.4. Python 2 is still community-supported | |
418 | on the bugfix only 5.x branch, but we remind you that Python 2 "end of life" |
|
514 | on the bugfix only 5.x branch, but we remind you that Python 2 "end of life" | |
419 | is on Jan 1st 2020. |
|
515 | is on Jan 1st 2020. | |
420 |
|
516 | |||
421 | We were able to backport bug fixes to the 5.x branch thanks to our backport bot which |
|
517 | We were able to backport bug fixes to the 5.x branch thanks to our backport bot which | |
422 | backported more than `70 Pull-Requests |
|
518 | backported more than `70 Pull-Requests | |
423 | <https://github.com/ipython/ipython/pulls?page=3&q=is%3Apr+sort%3Aupdated-desc+author%3Aapp%2Fmeeseeksdev++5.x&utf8=%E2%9C%93>`_, but there are still many PRs that required manual work. This is an area of the project where you can easily contribute by looking for `PRs that still need manual backport <https://github.com/ipython/ipython/issues?q=label%3A%22Still+Needs+Manual+Backport%22+is%3Aclosed+sort%3Aupdated-desc>`_ |
|
519 | <https://github.com/ipython/ipython/pulls?page=3&q=is%3Apr+sort%3Aupdated-desc+author%3Aapp%2Fmeeseeksdev++5.x&utf8=%E2%9C%93>`_, but there are still many PRs that required manual work. This is an area of the project where you can easily contribute by looking for `PRs that still need manual backport <https://github.com/ipython/ipython/issues?q=label%3A%22Still+Needs+Manual+Backport%22+is%3Aclosed+sort%3Aupdated-desc>`_ | |
424 |
|
520 | |||
425 | The IPython 6.x branch will likely not see any further release unless critical |
|
521 | The IPython 6.x branch will likely not see any further release unless critical | |
426 | bugs are found. |
|
522 | bugs are found. | |
427 |
|
523 | |||
428 | Make sure you have pip > 9.0 before upgrading. You should be able to update by running: |
|
524 | Make sure you have pip > 9.0 before upgrading. You should be able to update by running: | |
429 |
|
525 | |||
430 | .. code:: |
|
526 | .. code:: | |
431 |
|
527 | |||
432 | pip install ipython --upgrade |
|
528 | pip install ipython --upgrade | |
433 |
|
529 | |||
434 | .. only:: ipydev |
|
530 | .. only:: ipydev | |
435 |
|
531 | |||
436 | If you are trying to install or update an ``alpha``, ``beta``, or ``rc`` |
|
532 | If you are trying to install or update an ``alpha``, ``beta``, or ``rc`` | |
437 | version, use pip ``--pre`` flag. |
|
533 | version, use pip ``--pre`` flag. | |
438 |
|
534 | |||
439 | .. code:: |
|
535 | .. code:: | |
440 |
|
536 | |||
441 | pip install ipython --upgrade --pre |
|
537 | pip install ipython --upgrade --pre | |
442 |
|
538 | |||
443 |
|
539 | |||
444 | Or, if you have conda installed: |
|
540 | Or, if you have conda installed: | |
445 |
|
541 | |||
446 | .. code:: |
|
542 | .. code:: | |
447 |
|
543 | |||
448 | conda install ipython |
|
544 | conda install ipython | |
449 |
|
545 | |||
450 |
|
546 | |||
451 |
|
547 | |||
452 | Prompt Toolkit 2.0 |
|
548 | Prompt Toolkit 2.0 | |
453 | ------------------ |
|
549 | ------------------ | |
454 |
|
550 | |||
455 | IPython 7.0+ now uses ``prompt_toolkit 2.0``. If you still need to use an earlier |
|
551 | IPython 7.0+ now uses ``prompt_toolkit 2.0``. If you still need to use an earlier | |
456 | ``prompt_toolkit`` version, you may need to pin IPython to ``<7.0``. |
|
552 | ``prompt_toolkit`` version, you may need to pin IPython to ``<7.0``. | |
457 |
|
553 | |||
458 | Autowait: Asynchronous REPL |
|
554 | Autowait: Asynchronous REPL | |
459 | --------------------------- |
|
555 | --------------------------- | |
460 |
|
556 | |||
461 | Staring with IPython 7.0 on Python 3.6+, IPython can automatically ``await`` |
|
557 | Staring with IPython 7.0 on Python 3.6+, IPython can automatically ``await`` | |
462 | top level code. You should not need to access an event loop or runner |
|
558 | top level code. You should not need to access an event loop or runner | |
463 | yourself. To learn more, read the :ref:`autoawait` section of our docs, see |
|
559 | yourself. To learn more, read the :ref:`autoawait` section of our docs, see | |
464 | :ghpull:`11265`, or try the following code:: |
|
560 | :ghpull:`11265`, or try the following code:: | |
465 |
|
561 | |||
466 | Python 3.6.0 |
|
562 | Python 3.6.0 | |
467 | Type 'copyright', 'credits' or 'license' for more information |
|
563 | Type 'copyright', 'credits' or 'license' for more information | |
468 | IPython 7.0.0 -- An enhanced Interactive Python. Type '?' for help. |
|
564 | IPython 7.0.0 -- An enhanced Interactive Python. Type '?' for help. | |
469 |
|
565 | |||
470 | In [1]: import aiohttp |
|
566 | In [1]: import aiohttp | |
471 | ...: result = aiohttp.get('https://api.github.com') |
|
567 | ...: result = aiohttp.get('https://api.github.com') | |
472 |
|
568 | |||
473 | In [2]: response = await result |
|
569 | In [2]: response = await result | |
474 | <pause for a few 100s ms> |
|
570 | <pause for a few 100s ms> | |
475 |
|
571 | |||
476 | In [3]: await response.json() |
|
572 | In [3]: await response.json() | |
477 | Out[3]: |
|
573 | Out[3]: | |
478 | {'authorizations_url': 'https://api.github.com/authorizations', |
|
574 | {'authorizations_url': 'https://api.github.com/authorizations', | |
479 | 'code_search_url': 'https://api.github.com/search/code?q={query}{&page,per_page,sort,order}', |
|
575 | 'code_search_url': 'https://api.github.com/search/code?q={query}{&page,per_page,sort,order}', | |
480 | ... |
|
576 | ... | |
481 | } |
|
577 | } | |
482 |
|
578 | |||
483 | .. note:: |
|
579 | .. note:: | |
484 |
|
580 | |||
485 | Async integration is experimental code, behavior may change or be removed |
|
581 | Async integration is experimental code, behavior may change or be removed | |
486 | between Python and IPython versions without warnings. |
|
582 | between Python and IPython versions without warnings. | |
487 |
|
583 | |||
488 | Integration is by default with `asyncio`, but other libraries can be configured -- |
|
584 | Integration is by default with `asyncio`, but other libraries can be configured -- | |
489 | like ``curio`` or ``trio`` -- to improve concurrency in the REPL:: |
|
585 | like ``curio`` or ``trio`` -- to improve concurrency in the REPL:: | |
490 |
|
586 | |||
491 | In [1]: %autoawait trio |
|
587 | In [1]: %autoawait trio | |
492 |
|
588 | |||
493 | In [2]: import trio |
|
589 | In [2]: import trio | |
494 |
|
590 | |||
495 | In [3]: async def child(i): |
|
591 | In [3]: async def child(i): | |
496 | ...: print(" child %s goes to sleep"%i) |
|
592 | ...: print(" child %s goes to sleep"%i) | |
497 | ...: await trio.sleep(2) |
|
593 | ...: await trio.sleep(2) | |
498 | ...: print(" child %s wakes up"%i) |
|
594 | ...: print(" child %s wakes up"%i) | |
499 |
|
595 | |||
500 | In [4]: print('parent start') |
|
596 | In [4]: print('parent start') | |
501 | ...: async with trio.open_nursery() as n: |
|
597 | ...: async with trio.open_nursery() as n: | |
502 | ...: for i in range(3): |
|
598 | ...: for i in range(3): | |
503 | ...: n.spawn(child, i) |
|
599 | ...: n.spawn(child, i) | |
504 | ...: print('parent end') |
|
600 | ...: print('parent end') | |
505 | parent start |
|
601 | parent start | |
506 | child 2 goes to sleep |
|
602 | child 2 goes to sleep | |
507 | child 0 goes to sleep |
|
603 | child 0 goes to sleep | |
508 | child 1 goes to sleep |
|
604 | child 1 goes to sleep | |
509 | <about 2 seconds pause> |
|
605 | <about 2 seconds pause> | |
510 | child 2 wakes up |
|
606 | child 2 wakes up | |
511 | child 1 wakes up |
|
607 | child 1 wakes up | |
512 | child 0 wakes up |
|
608 | child 0 wakes up | |
513 | parent end |
|
609 | parent end | |
514 |
|
610 | |||
515 | See :ref:`autoawait` for more information. |
|
611 | See :ref:`autoawait` for more information. | |
516 |
|
612 | |||
517 |
|
613 | |||
518 | Asynchronous code in a Notebook interface or any other frontend using the |
|
614 | Asynchronous code in a Notebook interface or any other frontend using the | |
519 | Jupyter Protocol will require further updates to the IPykernel package. |
|
615 | Jupyter Protocol will require further updates to the IPykernel package. | |
520 |
|
616 | |||
521 | Non-Asynchronous code |
|
617 | Non-Asynchronous code | |
522 | ~~~~~~~~~~~~~~~~~~~~~ |
|
618 | ~~~~~~~~~~~~~~~~~~~~~ | |
523 |
|
619 | |||
524 | As the internal API of IPython is now asynchronous, IPython needs to run under |
|
620 | As the internal API of IPython is now asynchronous, IPython needs to run under | |
525 | an event loop. In order to allow many workflows, (like using the :magic:`%run` |
|
621 | an event loop. In order to allow many workflows, (like using the :magic:`%run` | |
526 | magic, or copy-pasting code that explicitly starts/stop event loop), when |
|
622 | magic, or copy-pasting code that explicitly starts/stop event loop), when | |
527 | top-level code is detected as not being asynchronous, IPython code is advanced |
|
623 | top-level code is detected as not being asynchronous, IPython code is advanced | |
528 | via a pseudo-synchronous runner, and may not advance pending tasks. |
|
624 | via a pseudo-synchronous runner, and may not advance pending tasks. | |
529 |
|
625 | |||
530 | Change to Nested Embed |
|
626 | Change to Nested Embed | |
531 | ~~~~~~~~~~~~~~~~~~~~~~ |
|
627 | ~~~~~~~~~~~~~~~~~~~~~~ | |
532 |
|
628 | |||
533 | The introduction of the ability to run async code had some effect on the |
|
629 | The introduction of the ability to run async code had some effect on the | |
534 | ``IPython.embed()`` API. By default, embed will not allow you to run asynchronous |
|
630 | ``IPython.embed()`` API. By default, embed will not allow you to run asynchronous | |
535 | code unless an event loop is specified. |
|
631 | code unless an event loop is specified. | |
536 |
|
632 | |||
537 | Effects on Magics |
|
633 | Effects on Magics | |
538 | ~~~~~~~~~~~~~~~~~ |
|
634 | ~~~~~~~~~~~~~~~~~ | |
539 |
|
635 | |||
540 | Some magics will not work with async until they're updated. |
|
636 | Some magics will not work with async until they're updated. | |
541 | Contributions welcome. |
|
637 | Contributions welcome. | |
542 |
|
638 | |||
543 | Expected Future changes |
|
639 | Expected Future changes | |
544 | ~~~~~~~~~~~~~~~~~~~~~~~ |
|
640 | ~~~~~~~~~~~~~~~~~~~~~~~ | |
545 |
|
641 | |||
546 | We expect more internal but public IPython functions to become ``async``, and |
|
642 | We expect more internal but public IPython functions to become ``async``, and | |
547 | will likely end up having a persistent event loop while IPython is running. |
|
643 | will likely end up having a persistent event loop while IPython is running. | |
548 |
|
644 | |||
549 | Thanks |
|
645 | Thanks | |
550 | ~~~~~~ |
|
646 | ~~~~~~ | |
551 |
|
647 | |||
552 | This release took more than a year in the making. |
|
648 | This release took more than a year in the making. | |
553 | The code was rebased a number of |
|
649 | The code was rebased a number of | |
554 | times; leading to commit authorship that may have been lost in the final |
|
650 | times; leading to commit authorship that may have been lost in the final | |
555 | Pull-Request. Huge thanks to many people for contribution, discussion, code, |
|
651 | Pull-Request. Huge thanks to many people for contribution, discussion, code, | |
556 | documentation, use-cases: dalejung, danielballan, ellisonbg, fperez, gnestor, |
|
652 | documentation, use-cases: dalejung, danielballan, ellisonbg, fperez, gnestor, | |
557 | minrk, njsmith, pganssle, tacaswell, takluyver , vidartf ... And many others. |
|
653 | minrk, njsmith, pganssle, tacaswell, takluyver , vidartf ... And many others. | |
558 |
|
654 | |||
559 |
|
655 | |||
560 | Autoreload Improvement |
|
656 | Autoreload Improvement | |
561 | ---------------------- |
|
657 | ---------------------- | |
562 |
|
658 | |||
563 | The magic :magic:`%autoreload 2 <autoreload>` now captures new methods added to |
|
659 | The magic :magic:`%autoreload 2 <autoreload>` now captures new methods added to | |
564 | classes. Earlier, only methods existing as of the initial import were being |
|
660 | classes. Earlier, only methods existing as of the initial import were being | |
565 | tracked and updated. |
|
661 | tracked and updated. | |
566 |
|
662 | |||
567 | This new feature helps dual environment development - Jupyter+IDE - where the |
|
663 | This new feature helps dual environment development - Jupyter+IDE - where the | |
568 | code gradually moves from notebook cells to package files as it gets |
|
664 | code gradually moves from notebook cells to package files as it gets | |
569 | structured. |
|
665 | structured. | |
570 |
|
666 | |||
571 | **Example**: An instance of the class ``MyClass`` will be able to access the |
|
667 | **Example**: An instance of the class ``MyClass`` will be able to access the | |
572 | method ``cube()`` after it is uncommented and the file ``file1.py`` is saved on |
|
668 | method ``cube()`` after it is uncommented and the file ``file1.py`` is saved on | |
573 | disk. |
|
669 | disk. | |
574 |
|
670 | |||
575 |
|
671 | |||
576 | .. code:: |
|
672 | .. code:: | |
577 |
|
673 | |||
578 | # notebook |
|
674 | # notebook | |
579 |
|
675 | |||
580 | from mymodule import MyClass |
|
676 | from mymodule import MyClass | |
581 | first = MyClass(5) |
|
677 | first = MyClass(5) | |
582 |
|
678 | |||
583 | .. code:: |
|
679 | .. code:: | |
584 |
|
680 | |||
585 | # mymodule/file1.py |
|
681 | # mymodule/file1.py | |
586 |
|
682 | |||
587 | class MyClass: |
|
683 | class MyClass: | |
588 |
|
684 | |||
589 | def __init__(self, a=10): |
|
685 | def __init__(self, a=10): | |
590 | self.a = a |
|
686 | self.a = a | |
591 |
|
687 | |||
592 | def square(self): |
|
688 | def square(self): | |
593 | print('compute square') |
|
689 | print('compute square') | |
594 | return self.a*self.a |
|
690 | return self.a*self.a | |
595 |
|
691 | |||
596 | # def cube(self): |
|
692 | # def cube(self): | |
597 | # print('compute cube') |
|
693 | # print('compute cube') | |
598 | # return self.a*self.a*self.a |
|
694 | # return self.a*self.a*self.a | |
599 |
|
695 | |||
600 |
|
696 | |||
601 |
|
697 | |||
602 |
|
698 | |||
603 | Misc |
|
699 | Misc | |
604 | ---- |
|
700 | ---- | |
605 |
|
701 | |||
606 | The autoindent feature that was deprecated in 5.x was re-enabled and |
|
702 | The autoindent feature that was deprecated in 5.x was re-enabled and | |
607 | un-deprecated in :ghpull:`11257` |
|
703 | un-deprecated in :ghpull:`11257` | |
608 |
|
704 | |||
609 | Make :magic:`%run -n -i ... <run>` work correctly. Earlier, if :magic:`%run` was |
|
705 | Make :magic:`%run -n -i ... <run>` work correctly. Earlier, if :magic:`%run` was | |
610 | passed both arguments, ``-n`` would be silently ignored. See :ghpull:`10308` |
|
706 | passed both arguments, ``-n`` would be silently ignored. See :ghpull:`10308` | |
611 |
|
707 | |||
612 |
|
708 | |||
613 | The :cellmagic:`%%script` (as well as :cellmagic:`%%bash`, |
|
709 | The :cellmagic:`%%script` (as well as :cellmagic:`%%bash`, | |
614 | :cellmagic:`%%ruby`... ) cell magics now raise by default if the return code of |
|
710 | :cellmagic:`%%ruby`... ) cell magics now raise by default if the return code of | |
615 | the given code is non-zero (thus halting execution of further cells in a |
|
711 | the given code is non-zero (thus halting execution of further cells in a | |
616 | notebook). The behavior can be disable by passing the ``--no-raise-error`` flag. |
|
712 | notebook). The behavior can be disable by passing the ``--no-raise-error`` flag. | |
617 |
|
713 | |||
618 |
|
714 | |||
619 | Deprecations |
|
715 | Deprecations | |
620 | ------------ |
|
716 | ------------ | |
621 |
|
717 | |||
622 | A couple of unused functions and methods have been deprecated and will be removed |
|
718 | A couple of unused functions and methods have been deprecated and will be removed | |
623 | in future versions: |
|
719 | in future versions: | |
624 |
|
720 | |||
625 | - ``IPython.utils.io.raw_print_err`` |
|
721 | - ``IPython.utils.io.raw_print_err`` | |
626 | - ``IPython.utils.io.raw_print`` |
|
722 | - ``IPython.utils.io.raw_print`` | |
627 |
|
723 | |||
628 |
|
724 | |||
629 | Backwards incompatible changes |
|
725 | Backwards incompatible changes | |
630 | ------------------------------ |
|
726 | ------------------------------ | |
631 |
|
727 | |||
632 | * The API for transforming input before it is parsed as Python code has been |
|
728 | * The API for transforming input before it is parsed as Python code has been | |
633 | completely redesigned: any custom input transformations will need to be |
|
729 | completely redesigned: any custom input transformations will need to be | |
634 | rewritten. See :doc:`/config/inputtransforms` for details of the new API. |
|
730 | rewritten. See :doc:`/config/inputtransforms` for details of the new API. |
General Comments 0
You need to be logged in to leave comments.
Login now