Hello, dear readers.
April 3, 2014 released the long-awaited release of
IPython under the number 2.0.
For those who do not know,
IPython is an interactive shell for the Python programming language, which provides extended introspection, additional command syntax, as well as highlighting and automatic code completion.
Further I will try to describe the most significant changes in comparison with the previous version. The main changes in it have undergone the IPython Notebook environment, about the innovations of which I will write below.
Major innovations
And so in the official
release the following innovations are listed:
- Added folder navigation in notebook
- New modal interface in notebook
- Ability to save a notebook work in various formats
- Interactive widgets when working with Ipython Notebook
- Improved security
')
New navigation
Those who previously worked with
IPython Notebook probably know how it is not convenient to work in the main window of the program, because all the *
.ipyb files should have been located in a specific folder and the user could not move around in her tree.
With the release of the new version, this flaw was finally eliminated and now we can navigate through folders of different levels, which is undoubtedly more convenient than it was before.

Modal interface
In the new version, 2 modes are available for each cell:
- Edit mode It is highlighted with a green frame and you can get into it by pressing the
enter
button.

- Command mode It is distinguished by a gray frame. In this mode, the cell is not available for editing. To change its contents, you need to put the cell in edit mode.

More details on the new interface described
here .
Export working notebook
Another great innovation is the addition of export formats to the console.

Users of the first version remember that there was only export to a python file (
.py). And in order to overtake the working console in the html
file * it was necessary to go to the console and execute the
nbconvert command with hands.
Now, as you can see from the screenshot, this is not necessary and the working IPython Notebook console can be converted to the html format with one click.
Interactive Widgets
Widgets allow you to create high-level interfaces for Python objects, such as functions. There is a standard set of widgets included in the release, and there is also an API for creating them. More information about the widgets, as well as examples of their use can be found in the
documentation.Enhanced security
In version 2.0, the console starts in
safe mode . In this mode:
- Trust is determined by the parameter at startup
- Untrusted HTML is being cleaned up.
- Untrusted javascript not executed
- In cells such as
markdown
JavaScript and HTML are considered not trusted if no parameter is defined in markdown
1.
Conclusion
At the end of the article I want to note that all the most significant changes were described, except for them there are a lot of any improvements and chips. A complete list, as well as documentation and examples of them can be found in the
release .