I'm playing around with a hand-rolled jupyter client, mainly to learn ZMQ and the jupyter messaging protocol.
My "client" starts a jupyter console and then starts sending messages to the shell channel / receiving from the shell and iopub channels. I notice that, often, I'm unable to read from the shell and iopub channels if I send a message as soon as possible after the console program starts. Like, my code does: 1. shell out a jupyter console, wait for return 2. poll the shell socket's ZMQ_EVENTS option until ZMQ_POLLOUT is true (incidentally, this always succeeds on the first poll) 3. send a message to the shell socket 4. poll the shell and iopub sockets' ZMQ_EVENTS options until ZMQ_POLLIN is true (both polls spin forever). If I make the code wait for a few seconds, the send and receive roundtrip completes just fine, a/k/a the polls at (4) succeed and my code continues. Can anybody point me to debug this? I tried starting the console with --log-level=DEBUG but none of the messages talk about what's going on at this level. Or, am I just doing the poll wrong? I would've though it would be fine to send when ZMQ_POLLOUT is true, but it looks like the kernel isn't receiving my message in this case. -- 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/20e29f70-cb0f-4c11-84a6-a94866b72098%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
