Why do Jupyter notebooks running Sage 6.9 kernel cause issues with SageMath Cloud's 6.10 kernel?

62 views
Skip to first unread message

Robert

unread,
Feb 14, 2016, 8:13:27 PM2/14/16
to sage-edu
Hi. I'm running a course right now in which I am making a lot of Jupyter notebooks for the students. I am doing this locally, using the SageMath 6.9 kernel. Recently SageMath Cloud went to the SageMath 6.10 kernel. I am hearing from students that now, when they upload the Jupyter notebooks to SMC to work with them, there's a message that comes up saying that the 6.9 kernel wasn't found, and they have to select a kernel from a list before it runs. (It looks like it only does this the first time the notebook is opened.) 

I was just curious as to why this is happening. The Jupyter notebook is just a bunch of text and some SageMath code, is it not?  It clearly knows that this is using the SageMath kernel otherwise it wouldn't say that the 6.9 kernel wasn't found. Why should it matter if the notebook was authored and run under the 6.9 kernel -- why should it give this message to choose the kernel, and why can it not just switch to the 6.10 kernel by default? 

I'm attaching one of the notebooks in case you wanted to see -- I don't believe that I'm using any code that would cause issues with the 6.10 kernel. 
lesson10.ipynb

William Stein

unread,
Feb 14, 2016, 8:53:44 PM2/14/16
to sage-edu
The explicit kernel spec in your ipynb file is -- very explicitly "sage 6.9":

"kernelspec": {
"display_name": "Sage 6.9",
"language": "",
"name": "sage_6_9"
},

Just open it and you will see. I don't know if Ipython has any sort
of "semantic versioning" for changing from one kernel to another. For
all Ipython knows, the kernel named "sage_6_9" is as related to the
one provided in SMC (called "SageMath 6.10") as to the Julia or Python
3 or any other kernel.

-- William
> --
> You received this message because you are subscribed to the Google Groups
> "sage-edu" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-edu+u...@googlegroups.com.
> To post to this group, send email to sage...@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-edu.
> For more options, visit https://groups.google.com/d/optout.



--
William (http://wstein.org)

William Stein

unread,
Feb 14, 2016, 8:55:54 PM2/14/16
to sage-edu
As a quick follow up, on SageMathCloud we just call the Sage kernel "sagemath":

"kernelspec": {
"display_name": "SageMath 6.10",
"language": "",
"name": "sagemath"
},

so notebooks will work from one version of Sage to another. But I
guess Volker (?) named the kernel for Ipython included with Sage
"sage_6_9".

-- William
--
William (http://wstein.org)

Volker Braun

unread,
Feb 16, 2016, 11:38:11 AM2/16/16
to sage-edu, Samuel Lelièvre, Nicolas M. Thiery
We used to include the version in the kernel name (up until sage-6.9, I guess) but then changed to "sagemath". Presumably this is why SMC calls the kernel "sagemath" nowadays, too. 

There are obvious pros and cons to storing the version, not every sage code ever written will run with every Sage version.
Reply all
Reply to author
Forward
0 new messages