Hello Claude,

the notebook server and the kernel where your code cells execute are two 
different processes. The notebook server cannot directly update the 
variables in your kernel.

You could translate the variable definitions received in your POST request 
to code, and send that code for execution to the kernel. Or you could 
define a custom message that the notebook server sends to the kernel, and 
install some handler code in the kernel that interprets these messages. The 
second approach has the advantage that you don't need language-specific 
logic in the notebook server.
https://jupyter-client.readthedocs.io/en/stable/messaging.html

Either way, allowing an external server to send POST requests that change 
the state of kernel processes sounds like an attack vector. Please be very 
careful to properly authenticate these requests.

hope this helps,
  Roland

-- 
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/d779575f-bd24-4e14-a235-01a8606d2ce6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to