Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

%attach/attach() does not work in sage jupyter (sage 7.5.1)

Whenever I open a jupyter notebook in Sage 7.5.1 (sage -n jupyter), issuing a magic command

%attach myfile.py

or an inline attachcommand

attach("muyfile.py")

results in an error:

UsageError: Invalid GUI request 'sage', valid ones are:['osx', 'qt4', 'qt5', 'nbagg', None, 'gtk', 'gtk3', 'notebook', 'tk', 'inline', 'wx', 'qt']

I found this error in sagemath 7.5.1, but it is not present in sagemath 7.2. The magic %load, however, works.

Any workarounds? (besides changing %attach to %load, I mean.)