Cannot load .sws file into Sage; using windows and Oracle VirtualBox

435 views
Skip to first unread message

Dennis Eichhorn

unread,
Jun 3, 2014, 4:08:08 AM6/3/14
to sage-s...@googlegroups.com
Running Windows 7, with Oracle VirtualBox as suggested.  I am trying to take my notebook (worksheet?) from another computer and open it in Sage.  I managed to get the file from the original computer using publish.  I put the file onto my new computer, in a shared a folder I created following the online instructions (http://wiki.sagemath.org/SageAppliance), and am at the sage command line, in the directory of my shared folder (/media/sf_blah), looking at the file that I think is a copy of my notebook.  Now what?  load and attach both give error messages.  My notebook is X.sws   .  When I try to load it, it seems to add a file extension; I get " [Errno 2] No such file or directory: 'X.sws.sobj' ". When I try to attach, I get " ValueError: argument (='X.sws') to load or attach must have extension py, pyx, sage, spyx, or m" .

Better would be, is there a way to load the .sws from the usual graphical interface?

Also, the instructions say that pressing Right-Ctrl and F2 return me to the graphical Sage window, but it doesn't.

P Purkayastha

unread,
Jun 3, 2014, 4:30:21 AM6/3/14
to sage-s...@googlegroups.com
sws file should be "uploaded" to the sage notebook. There is an "Upload" link towards the top of the notebook, when you open the notebook for the first time. It can not be opened from the command line (or maybe it can be, but you will need to write some extra python commands/script).

Can you check if Right-Ctrl + F1, or Right-Ctrl + Alt + F1 works, or if Right-Ctrl + Alt + F7 works to return you to the graphical sage window? In fact, you can try all the combinations F1 to F7!

Dennis Eichhorn

unread,
Jun 4, 2014, 1:06:00 AM6/4/14
to sage-s...@googlegroups.com


That worked; infinite thanks.  I will mention to future folks with the same problem that I had to type in the address in the "Location:" bar after clicking upload.  I had been trying to navigate to it with the locations listed on the left, and I couldn't find it.  I typed in " /media/sf_folder/file.sws "  Where the shared folder I had created was C:/Users/Me/blahblahblah/folder .  Somehow, it just takes the folder name without the path to it, and appends " sf_ " to the front of it.  I had put file.sws in C:/Users/Me/blahblahblah/folder on my new computer.  It took me a while to pull it off my old computer, too.  I did so by, in my open worksheet, clicking "publish", and then opening a web browser in windows, going to the location it told me after I published, which was http://localhost:8000/pub/0/ , and then clicking download.  file.sws was then in my Downloads folder in windows, and I took it from there.

Thanks again, and I hope future troubleshooters will benefit from my short story.

PS - at some point, Right-Ctrl + F7 worked!  Thanks for that, too!  On a different machine, Right-Ctrl + F2 worked fine.
Reply all
Reply to author
Forward
0 new messages