[IPython-dev] A Kernel for Java, Scheme, Boo, Logo, Basic, and more
Doug Blank
doug.blank at gmail.com
Tue Jan 28 12:11:52 EST 2014
On Sun, Jan 26, 2014 at 5:19 PM, Gabriel Becker <gmbecker at ucdavis.edu>wrote:
> Doug,
>
> This looks very interesting (no love for R though? :( ). Nice work.
>
>
So, this system is a collection of all of the languages that we can run on
a VM (like Mono and .NET's CLR or JVM; we use IKVM to move bytes from one
VM to the other). So, if you know of an implementation of R for one of the
virtual machines, we'd gladly use it.
> Have you considered differentiating the languages by the cells/messages
> themselves, rather than directvies within the cell's contents?
>
> I have always thought that code language would be better as an attribute
> of the code itself and a distinct part of the message sent. The magics work
> the way they do because technically they are still IPython code, and are
> evaluated with the IPython evaluator. If your kernel is doing the dispatch
> to different evaluators itself, though, there is no need to stick to that
> paradigm.
>
>
You are absolutely correct that this is a concern, especially for use with
those metacommands that change global state. If you rearrange the cells,
you might be in a different state (ie, language) and then it fails. In our
own IDE, we keep track of shell history, and keep the executing language at
the time with it.
In reality, jumping from one language to another is not yet the norm for
many programmers (unless one of the languages is bash). Also, I would only
be interested in considering such an option if there were developed a
standard API in IPython for the kernel to talk to the frontend, and an API
for setting/getting cell values. We hope that our kernel will be part of
the IPython ecosystem.
-Doug
> Just my 2 cents.
> ~G
>
>
>
> On Sun, Jan 26, 2014 at 12:58 PM, Doug Blank <doug.blank at gmail.com> wrote:
>
>> On Sun, Jan 26, 2014 at 3:28 PM, Brian Granger <ellisonbg at gmail.com>wrote:
>>
>>> Doug,
>>>
>>> Awesome, thanks so much for sharing this! I had a quick look. I really
>>> like the :lang abstraction, especially how it is stateful when run in
>>> a cell by itself. It will be fun to watch where this goes. Having
>>> learned to program with logo, I am especially interested in seeing
>>> where that goes. Have you been able to get the pyout and display_data
>>> messages working for rich output?
>>>
>>>
>> Thanks! Actually, I am trying to figure out how display_data and rich
>> messages work right now. I see the mime-type keys in the data dictionary,
>> but having some trouble figuring out how they get there from a function
>> wrapped around a value. Is there an overview that describes the approach?
>> Or maybe you can point me to the relevant code? I suspect that the Python
>> kernel side of things has a nice infrastructure... but what is the simplest
>> approach just as proof of concept to get, say, a gif to appear in the
>> notebook?
>>
>> -Doug
>>
>>
>>
>>> Cheers,
>>>
>>> Brian
>>>
>>> On Sun, Jan 26, 2014 at 11:40 AM, Doug Blank <doug.blank at gmail.com>
>>> wrote:
>>> > Just a quick status update on a new kernel. Once I got the
>>> simple_kernel.py
>>> > [1] written and understood, at least to a level, we were able to make
>>> fast
>>> > progress (a few afternoon hacks) on the real project. This new kernel
>>> is
>>> > written in C# [2], but is really a wrapper around a set of languages,
>>> > including Java, Scheme, Boo, Logo, Python, Ruby, Basic, and some
>>> others,
>>> > including an assembly language.
>>> >
>>> > Not only can you run all of these via notebook, console, and
>>> qtconsole, but
>>> > many of the languages share data and functions with each other. Here
>>> is a
>>> > pointer to a top-level notebook (refresh, as it is changing quickly):
>>> >
>>> >
>>> http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Calico%20Overview.ipynb
>>> >
>>> > Still a lot to do, but just wanted to point to recent results, and say
>>> > thanks for the help so far!
>>> >
>>> > -Doug
>>> >
>>> >
>>> > [1] - https://github.com/dsblank/simple_kernel/blob/master/README.md
>>> > [2] -
>>> >
>>> https://bitbucket.org/ipre/calico/src/master/Source/Calico/ZMQServer.cs?at=master
>>> >
>>> >
>>> >
>>> > _______________________________________________
>>> > IPython-dev mailing list
>>> > IPython-dev at scipy.org
>>> > http://mail.scipy.org/mailman/listinfo/ipython-dev
>>> >
>>>
>>>
>>>
>>> --
>>> Brian E. Granger
>>> Cal Poly State University, San Luis Obispo
>>> bgranger at calpoly.edu and ellisonbg at gmail.com
>>> _______________________________________________
>>> IPython-dev mailing list
>>> IPython-dev at scipy.org
>>> http://mail.scipy.org/mailman/listinfo/ipython-dev
>>>
>>
>>
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> http://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>
>
> --
> Gabriel Becker
> Graduate Student
> Statistics Department
> University of California, Davis
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140128/06fed58b/attachment.html>
More information about the IPython-dev
mailing list