Here is what i’d like to do: From a running python process, upgrade it to an IPython Jupyter kernel, which shares the local and global variables and can be accessed by other Jupyter clients.
I have found IPython.embed
which upgrades the session (but does not give me a Kernel connection information afaics). I’ve also found ipykernel.ipkernel.IPythonKernel
, which also appears to start an embedded ipython shell but also does not give me a jupyter kernel connection info.
Context: I want to do this from an external wrapper program which interacts with CPython via the python C api; this is why I can’t simply start an IPython kernel in the first place.