[IPython-dev] Using jupyter_console as embedded shell
Thomas Kluyver
takowl at gmail.com
Thu Dec 3 05:02:34 EST 2015
On 3 December 2015 at 07:26, Frédéric Mantegazza <mantegazza at ill.fr> wrote:
> Is there a direct matching of the InteractiveShellEmbed in
> jupyter_console ?
>
There isn't, because it doesn't really make sense. Embedding an IPython
shell gives you interactive access to the namespace in which you invoke it
- it's like launching a debugger with pdb.set_trace(). jupyter_console is
for communicating with a kernel in a separate process, so you can't embed
it in the namespace where you created it.
You can embed the IPython kernel by calling IPython.embed_kernel(), and
then connect a console to it from another terminal, if that's what you want.
Or if you just want to start jupyter_console programmatically, without
worrying about the namespace, I think that's jupyter_console.app.main().
Passing existing=True should be equivalent to --existing on the command
line.
Thomas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20151203/139e6ba7/attachment.html>
More information about the IPython-dev
mailing list