-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
API design #1
Comments
So far, we expose |
I think implementing the ocaml kernel on top of this will help expose all the required functionality. stdout/stderr (and potentially stdin) might need some thought. |
Yes indeed. Would you be willing to migrate iocaml here, and try and use the new API in it? I will migrate my own project (easy, since it already uses this API). We might also want to bring people from Owl (@ryanrhymes) and other ML/numerical libs in there, it would help design a good API for mime data (pictures, mostly). Sorry if it's already working automatically in the old iocaml. |
Indeed, I definitely intend to port the ocaml kernel across and make it live here. (Not before the new year though...) Regarding MIME stuff it should just work.....98% of that is actually handled in the javascript on the web front end. I will look into it. |
If you have time to look at the current API, it would be great! :-) |
Will do. I will ensure that everything that used to work in iocaml still does when I port it across, including mime, stdio stuff and whatever else I find (but also clean up some stuff that didn't work out too). |
I've been using mime types myself (can at least display a .png in the notebook after base64 encoding) but not the stdio part. However, it should not have changed much, except it should use lwt-zmq :-) |
Yeah - the stdio stuff has specific messages I seem to remember. In iocaml there's a bit of |
I think that reading stdin/printing on stdout should be done on the frontend side (jupyter-console, etc.), so not a concern to the kernel itself. Of course if some executed code contains But draining a channel concurrently to the main loop is very easy with lwt; I'd say it easier than with blocking IO + threads, actually. If it's not, we can use lwt.preemptive. |
https://jupyter-client.readthedocs.io/en/latest/messaging.html using this as a ref, btw. Will look into the "stream" part tomorrow. |
I added a |
I now have two (basic) kernels on top of that library. |
Note that completion and inspection work (and they are compliant with later versions of the protocole, by using offsets expressed in number of codepoints). |
We need to discuss the design of this library, how it can be used for various kernels, what capabilities does it expose, etc.
cc @andrewray .
The text was updated successfully, but these errors were encountered: