I find one simpler approach to do that, just ues jupyter_client api. But I
could not get the execute response correctly. Could anyone help on that ?
Thanks
Here's my sample code
import jupyter_client
kernel_manager, kernel_client =
jupyter_client.manager.start_new_kernel(kernel_name='python3')
kernel_client.execute("print('hello world')")
kernel_client.get_shell_msg()
在 2017年7月2日星期日 UTC+8上午8:09:48,rgbkrk写道:
>
> Hey Jeff,
>
> This is the protocol:
> http://jupyter-client.readthedocs.io/en/latest/messaging.html
>
> It's worth taking a look at how the notebook serves up the protocol on
> websockets and communicates with them from frontends:
> https://github.com/jupyter/notebook
>
>
> On Sat, Jul 1, 2017 at 4:15 PM, Jeff Zhang <[email protected] <javascript:>
> > wrote:
>
>> I found the following link on how to embed ipython into other third party
>> tools. But what I want is not interact ipython via shell, what I want is
>> something like jupyter notebook.
>> So I think I need to start ipython kernel in a separate process, and then
>> communicate it with RPC. Does anyone know the IPython's rpc protocol or
>> what kind of API I can use to interact with ipython kernel.
>>
>> 在 2017年7月1日星期六 UTC+8下午10:23:37,Jeff Zhang写道:
>>>
>>>
>>> I'd like to integrate IPython kernel in thrift party software, do python
>>> REPL in third party software. But I could not find document about how to
>>> integrate IPython kernel to third party software.
>>>
>>> Could anyone point me some materials on that ? Thanks
>>>
>>>
>>> --
>> You received this message because you are subscribed to the Google Groups
>> "Project Jupyter" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected] <javascript:>.
>> To post to this group, send email to [email protected]
>> <javascript:>.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/jupyter/db4f20ae-55e5-4d4d-94eb-fcea6bf87dbd%40googlegroups.com
>>
>> <https://groups.google.com/d/msgid/jupyter/db4f20ae-55e5-4d4d-94eb-fcea6bf87dbd%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Kyle Kelley (@rgbkrk <https://twitter.com/rgbkrk>; lambdaops.com)
>
--
You received this message because you are subscribed to the Google Groups
"Project Jupyter" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jupyter/f6636714-c597-4f49-bc70-38e8275ecd3d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.