development.txt
89 lines
| 3.4 KiB
| text/plain
|
TextLexer
Fernando Perez
|
r5793 | ===================== | ||
Development version | ||||
Brian Granger
|
r2275 | ===================== | ||
Fernando Perez
|
r5793 | This document describes in-flight development work. | ||
Thomas Kluyver
|
r4147 | |||
Thomas Kluyver
|
r6184 | Redesigned IPython notebook user interface | ||
------------------------------------------ | ||||
Thomas Kluyver
|
r7442 | (Add description & screenshots of the many changes to the notebook) | ||
Cell magics | ||||
----------- | ||||
IPython's ``%magic`` functions have been extended to let you change the meaning | ||||
of a whole cell using the first line. For example, to time the execution of | ||||
several statements:: | ||||
%%timeit x = 0 # setup | ||||
for i in range(100000): | ||||
x += i**2 | ||||
This is particularly useful to integrate code in another language, and cell | ||||
magics already exist for shell scripts, Cython, R and Octave. Using ``%%script | ||||
/usr/bin/foo``, you can run a cell in any interpreter that accepts code via | ||||
stdin. | ||||
Another handy cell magic makes it easy to write short text files: ``%%file | ||||
~/save/to/here.txt``. | ||||
To allow these features, the API for magic functions has been refactored and | ||||
made more powerful (:ghpull:`1732`). | ||||
Interactive tab completion for the Qt console | ||||
--------------------------------------------- | ||||
(Add description & screenshots) (:ghpull:`1851`) | ||||
Thomas Kluyver
|
r6184 | |||
Matthias BUSSONNIER
|
r7443 | |||
Completer improvement | ||||
--------------------- | ||||
One of the great feature of IPython is the ability to inspect live element and | ||||
provide useful completion to the user, this one base of interactive | ||||
exploration of data. To make this process even more user-friendly the completers | ||||
of both the QTconsole and the Notebook has been reworked. | ||||
The Qtconsole --gui-completion flag came with a new `ncurses` flavor, activated | ||||
by default, which allows to cycle through the available completion by pressing | ||||
tab, and to navigate the with the arrow keys.(:ghpull:`1851`) | ||||
As part of the great refactoring of the notebook's JavaScript, the completer | ||||
has been partially rewritten. Completions are now sourced both from object | ||||
introspection and analyse of surrounding code, allowing to get a even limited | ||||
completion on code not executed, or even while the kernel is busy. | ||||
Thomas Kluyver
|
r6184 | Other new features | ||
------------------ | ||||
* **%install_ext**: A new magic function to install an IPython extension from | ||||
Thomas Kluyver
|
r7442 | a URL. E.g. ``%install_ext | ||
https://bitbucket.org/birkenfeld/ipython-physics/raw/default/physics.py``. | ||||
* The ``%loadpy`` magic is no longer restricted to Python files, and has been | ||||
renamed ``%load``. The old name remains as an alias. | ||||
* New command line arguments will help external programs find IPython folders: | ||||
``ipython locate`` finds the user's IPython directory, and ``ipython locate | ||||
profile foo`` finds the folder for the 'foo' profile (if it exists). | ||||
Thomas Kluyver
|
r6184 | |||
Bradley M. Froehle
|
r6702 | * The :envvar:`IPYTHON_DIR` environment variable, introduced in the Great | ||
Reorganization of 0.11 and existing only in versions 0.11-0.13, has been | ||||
deprecated. As described in :ghissue:`1167`, the complexity and confusion of | ||||
migrating to this variable is not worth the aesthetic improvement. Please use | ||||
the historical :envvar:`IPYTHONDIR` environment variable instead. | ||||
Thomas Kluyver
|
r6184 | |||
Mike Hansen
|
r7033 | * The default value of *interactivity* passed from | ||
:meth:`~IPython.core.interactiveshell.InteractiveShell.run_cell` to | ||||
:meth:`~IPython.core.interactiveshell.InteractiveShell.run_ast_nodes` | ||||
is now configurable. | ||||
Bradley M. Froehle
|
r7334 | |||
Backwards incompatible changes | ||||
------------------------------ | ||||
* The exception :exc:`IPython.core.error.TryNext` previously accepted | ||||
arguments and keyword arguments to be passed to the next implementation | ||||
of the hook. This feature was removed as it made error message propagation | ||||
difficult and violated the principle of loose coupling. | ||||