[IPython-dev] thoughts on the notebook, alternative front-ends and remote editing
Damien Drix
damien.drix at gmail.com
Wed Mar 4 08:57:43 EST 2015
The IPython notebook has changed the way I work. Literate programming,
the merging of experiment scripts and experiment reports into a single
document, and countless other productivity gains: tweaking matplotlib
graphs interactively, easy parallelism, etc. It is quite awesome!
Could it be improved? It certainly can. Here are the two points I find
most prominent:
- After one has gotten used to SublimeText & co, CodeMirror just hurts.
- The notebook server has huge potential for remote work, but this
potential is partly unexploitable because of some aspects of the
client/server architecture.
Let me explain the latter point. I have a fairly beefy desktop machine in
my office, but I'm often working from other locations. I'd like to be
able to open a notebook remotely on my laptop, edit it, start some long-
running computations, close my laptop, go to lunch, and come back to it
in the afternoon to see the results.
Right now, it... kind of works. But the issue is that since the execution
of cells is orchestrated by client-side javascript, at most one cell will
be executed if I close the client. The results are there in the kernel
namespace, but the outputs are lost -- integrating the outputs into the
notebook is also done by client-side scripts. The client also loses track
of which cells are still being executed.
One solution would be to use X forwarding and keep the notebook client
running on the desktop machine, but in my case the connection lag makes
text editing quite unbearable. I prefer to connect to the notebook server
from a local client process.
Here is the solution I was thinking about:
- A new frontend app where, instead of embedding a text editor into the
notebook, the notebook itself is embedded into a text editor. A number of
nice, open-source, SublimeText-class editors are already being developed:
Atom, LimeText, LightTable, etc. LightTable has actually done some work
on integrating the IPython kernel and displaying results inline. I
imagine that it wouldn't be unreasonably hard to turn it into a full
notebook client. As a bonus, no more juggling between two editors: use
the same for the notebooks and for plain Python scripts!
- Move the task of supervising cell execution and integrating the outputs
into the notebook model from the client to the server, so that notebooks
can keep running when the client disconnects.
- Let the client app refresh its view of the notebook when it reconnects
to the server, showing the new outputs and which cells are still running.
Any thoughts on this? Is it all maybe already happening in the Jupyter
project? ;-)
Best,
Damien
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20150304/33c10d91/attachment.html>
More information about the IPython-dev
mailing list