Coming SageMathCell upgrade - please test!

141 views
Skip to first unread message

Andrey Novoseltsev

unread,
Apr 17, 2016, 8:29:51 PM4/17/16
to sage-notebook, sage-devel, sage-support, sage-edu
Hello and sorry for cross-posting, I'm trying to maximize visibility.

After quite a few changes I have a version of SageMathCell running Sage-7.1 and using Jupyter etc. shipped with Sage, rather than a custom old branch of IPython.

User-visible changes should be minimal, but there are some for script interaction that will probably require changes to Android app, WebWorks, and what else.

There may be also new bugs introduced in the process. I hope that most of the stuff is done correctly and I will do some more testing/fixing/documenting over the next month or so, but it would be nice if other people tried it with their favourite code, interacts, web-pages, etc. To help with this I've pushed all changed to master, so those who have their own installations should be using the new version, and I have also set up a test instance on our Madrid server:
http://cosmos.mat.uam.es:8888/
for comparison you can also use old version at
http://cosmos.mat.uam.es/

Thank you!
Andrey

Kwankyu Lee

unread,
Apr 17, 2016, 10:49:55 PM4/17/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
The webpage from the Madrid server opens but contains no Sage cell. My web browser is Chrome on Mac. Accessing from Asia might be a cause.

mmarco

unread,
Apr 18, 2016, 2:34:58 AM4/18/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
Same Here.

mmarco

unread,
Apr 18, 2016, 2:35:34 AM4/18/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
Forgot to mention, I am using chromium in Linux.

Bruno Grenet

unread,
Apr 18, 2016, 3:50:27 AM4/18/16
to sage-...@googlegroups.com, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com, mmarco
Works fine on Firefox 45.0 in Linux Mint.
> --
> You received this message because you are subscribed to the Google
> Groups "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to sage-devel+...@googlegroups.com
> <mailto:sage-devel+...@googlegroups.com>.
> To post to this group, send email to sage-...@googlegroups.com
> <mailto:sage-...@googlegroups.com>.
> Visit this group at https://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.

Dima Pasechnik

unread,
Apr 18, 2016, 4:13:48 AM4/18/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
works on firefox, but does not give a window to evaluate on Chrome, 49.0.2623.87 (64-bit) (both browsers the same machine, on Ubuntu 14.04)

Thierry

unread,
Apr 18, 2016, 4:58:49 AM4/18/16
to sage-...@googlegroups.com, sage-notebook, sage-support, sage-edu
Hi,

it works almost well on iceweasel (Firefox 38.7.1) on Debian jessie
(stable). I see however two issues.

First, autocompletion does not work, when i click on <TAB>, the cursor
jumps on "Evaluate" button. I tried on the older version and it works, so
it is a regression.

Second, when trying a plot3d (type "dodecahedron()"), i got an image, but
when i click to animate it, i got an error message:

Error connecting to server:
http://your.server.here/jsmol.php?call=getRawDataFromDatabase&database=_&query=http%3A%2F%2Fcosmos.mat.uam.es%3A8888%2Fkernel%2F7af3de4b-ec65-44a7-8f53-f279879ffa9d%2Ffiles%2F.%2FtmpQwiiT9.jmol%2Fscene.zip&encoding=base64

It seems that you have to replace your.server.here somewhere in the conf.

Actually, i am noticing that the same error appears on the current
version, i am not using sagecell, so i did not notice that failure before
(this test is part of my "human testsuite" for releasing Sage Debian Live).

Ciao and thanks for maintaining sagecell,
Thierry
> --
> You received this message because you are subscribed to the Google Groups "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
> To post to this group, send email to sage-...@googlegroups.com.

Eric Gourgoulhon

unread,
Apr 18, 2016, 10:00:17 AM4/18/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
Hi,

Le lundi 18 avril 2016 10:58:48 UTC+2, Thierry (sage-googlesucks@xxx) a écrit :
Hi,

it works almost well on iceweasel (Firefox 38.7.1) on Debian jessie
(stable). I see however two issues.

First, autocompletion does not work, when i click on <TAB>, the cursor
jumps on "Evaluate" button. I tried on the older version and it works, so
it is a regression.

I confirm; same problem here with Firefox 43.0.4 / Ubuntu 15.10.

Second, when trying a plot3d (type "dodecahedron()"), i got an image, but
when i click to animate it, i got an error message:

Error connecting to server:
http://your.server.here/jsmol.php?call=getRawDataFromDatabase&database=_&query=http%3A%2F%2Fcosmos.mat.uam.es%3A8888%2Fkernel%2F7af3de4b-ec65-44a7-8f53-f279879ffa9d%2Ffiles%2F.%2FtmpQwiiT9.jmol%2Fscene.zip&encoding=base64

It seems that you have to replace your.server.here somewhere in the conf.
 
dodecahedron() works well for me with Firefox 43.0.4 / Ubuntu 15.10.

Best wishes,

Eric.
 

Andrey Novoseltsev

unread,
Apr 18, 2016, 11:40:18 PM4/18/16
to sage-devel, sage-n...@googlegroups.com, sage-support, sage...@googlegroups.com
To summarize what was discovered so far:

1) Chrome does not work: I unfortunately tend to forget that different
browsers/OS should be tested - I was working on Firefox under Debian,
will try to fix is next weekend. Location should not matter when you
use the name of the server directly (sagecell.sagemath.org does
resolve to Madrid for certain locations).
2) TAB completion does not work: also didn't test as I rarely write
code in cells, will try to fix next weekend as well.
3) 3d plots have issues: these are likely to be the same as in the old
version - it will be a high priority to improve the situation after
the switch to Jupyter is done.

Any issues with interacts or embedding?

Andrey Novoseltsev

unread,
Apr 24, 2016, 9:10:04 PM4/24/16
to sage-devel, sage-n...@googlegroups.com, sage-support, sage...@googlegroups.com
Update:

1) Chrome does not work because of executing
sagecell.makeSagecell(...)
before
<script src="{{ static_url('embedded_sagecell.js') }}"></script>
finishes while Firefox waits till the script is processed. The issue
goes away if I wrap makeSagecell call in require(...), but I have no
idea how to make it work without, which is necessary for supporting
old pages. Any pointers?... I can't say I am a big fan of RequireJS,
but it felt natural to use it because Jupyter uses it. Should I
perhaps use something else instead/in addition?

2) TAB-completion should be fixed.
3) No progress on 3D yet.
4) Didn't look into CORS problems with embedding yet.

Volker Braun

unread,
Apr 25, 2016, 4:35:20 AM4/25/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
sagecell.makeSagecell is already polling to see whether it is loaded; thats of course totally fugly but should work. You just have to make sure that it is defined. If its only defined once a requirejs module loads then you don't have control over when. Instead move the

window.sagecell = window.sagecell || {};
sagecell.makeSagecell = function (args, k) {
...
}

outside of requirejs to always define the entrypoint into sagecell.

Andrey Novoseltsev

unread,
May 1, 2016, 8:33:18 PM5/1/16
to sage-n...@googlegroups.com, sage-devel, sage-support, sage...@googlegroups.com
Made it work in Chrome via
https://github.com/sagemath/sagecell/commit/95d2b406026ea7efc73a91ef693a1dd9fb5946c6
(my attempts to create all wrappers using a loop were not successful)

Made some progress on CORS but there are still issues.
> --
> You received this message because you are subscribed to the Google Groups
> "sage-notebook" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-noteboo...@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-notebook.

Andrey Novoseltsev

unread,
May 1, 2016, 9:56:37 PM5/1/16
to sage-n...@googlegroups.com, sage-devel, sage-support, sage...@googlegroups.com
OK, embedding seems to work for Chrome and Firefox, so reported
regressions are fixed.

I am planning to switch main servers in 3 weeks. (Probably 7.2 will be
out by then, so I'll also see how easy it is to upgrade with the new
setup.)

Andrey Novoseltsev

unread,
May 15, 2016, 2:37:57 PM5/15/16
to sage-n...@googlegroups.com, sage-devel, sage-support, sage-edu
The test server
http://cosmos.mat.uam.es:8888/
is now running 7.2.rc2 with upgraded ipykernel which greatly helped
with stability.

If no major issues are discovered by the next weekend (which will be
long for me and I will have a bit more time), I will roll this version
to all public servers and proceed fixing problems from there.

One problem is how 3d plots work (or rather don't), but given their
current state I don't consider it a blocker.

Thank you!
Andrey

Andrey Novoseltsev

unread,
May 20, 2016, 11:59:37 PM5/20/16
to sage-n...@googlegroups.com, sage-devel, sage-support, sage-edu
OK, I've pressed the button - http://sagecell.sagemath.org is now
running the latest version of Sage 7.2, together with a "significantly
touched up" version of the SageMathCell code itself.

Please report any new (or old) errors that you notice - I will try to
fix them tomorrow (Saturday) afternoon (MST) and on Sunday/Monday. If
something is horribly wrong and I can't resolve it by Monday evening,
I'll pull back to the old version.

Thank you,
Andrey

kcrisman

unread,
May 26, 2016, 12:34:11 PM5/26/16
to sage-notebook, sage-...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com

Please report any new (or old) errors that you notice - I will try to
fix them tomorrow (Saturday) afternoon (MST) and on Sunday/Monday. If
something is horribly wrong and I can't resolve it by Monday evening,
I'll pull back to the old version.


http://ask.sagemath.org/question/33555/problem-with-encoding-german-characters/ could be related, or so the poster seems to imply - though probably not bad enough to go back before 7.2.

Andrey Novoseltsev

unread,
May 26, 2016, 6:30:33 PM5/26/16
to sage-notebook, sage-...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
On Thursday, 26 May 2016 10:34:07 UTC-6, kcrisman wrote:
http://ask.sagemath.org/question/33555/problem-with-encoding-german-characters/ could be related, or so the poster seems to imply - though probably not bad enough to go back before 7.2.

Thanks a lot for pointing it out - this is the worst problem I am currently aware of and it is definitely new. Would be solved by a switch to Python3, I guess ;-)

Overall things seem to be good enough that I don't plan a reversal anymore.

Ivan Andrus

unread,
May 26, 2016, 11:59:06 PM5/26/16
to sage-n...@googlegroups.com, sage-...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
Over the past few days I’ve gotten several complaints about the iOS sage app being broken.  Unfortunately, I missed the message that you were upgrading the cell server, so I didn’t know where to look immediately.

The method that the app uses is to load a webpage with an embedded sage cell in it, with some options other stuff to communicate back to the app.  The template webpage is 


Perhaps you will be able to look at it and notice that I’m doing something bad.  

-Ivan

Andrey Novoseltsev

unread,
May 29, 2016, 8:30:01 PM5/29/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com

This should be fixed now - I had to encode user code when writing to a file for correct warning messages.

Peter Luschny

unread,
Jun 6, 2016, 4:14:28 AM6/6/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-1-2ef73eaf42ab> in <module>()
----> 1 load('http://....')
      2 load('http://....')
      3 

/home/sc_serv/sage/src/sage/structure/sage_object.pyx in sage.structure.sage_object.load (/home/sc_serv/sage/src/build/cythonized/sage/structure/sage_object.c:11408)()
   1016 
   1017     if sage.repl.load.is_loadable_filename(filename):
-> 1018         sage.repl.load.load(filename, globals())
   1019         return
   1020 

/home/sc_serv/sage/local/lib/python2.7/site-packages/sage/repl/load.pyc in load(filename, globals, attach)
    252             raise NotImplementedError("you can't attach a URL")
    253         from sage.misc.remote_file import get_remote_file
--> 254         filename = get_remote_file(filename, verbose=False)
    255 
    256     from sage.repl.attach import load_attach_path

/home/sc_serv/sage/local/lib/python2.7/site-packages/sage/misc/remote_file.pyc in get_remote_file(filename, verbose)
     34 
     35     # import compatible with py2 and py3
---> 36     from six.moves.urllib.request import urlretrieve
     37 
     38     global cur

ImportError: No module named moves.urllib.request

Andrey Novoseltsev

unread,
Jun 10, 2016, 1:22:59 AM6/10/16
to sage-devel, sage-n...@googlegroups.com, sage-s...@googlegroups.com, sage...@googlegroups.com, sage...@googlegroups.com
This is due to the bug fixed by http://trac.sagemath.org/ticket/20797

Also, I'll try to keep further discussion of SageMathCell at https://groups.google.com/forum/#!forum/sage-cell
Reply all
Reply to author
Forward
0 new messages