The server which had the problem was running 4.3. On the same machine I started another server using 4.3.1.alpha1 and there was no problem. That was with my usual user account, not the sage account.
>From the sage account, I copied my 4.3.1.alpha1 build from my own user account, but I could not get it to work properly. So now I'm feeling really stupid since I don't seem to be able to try what you suggested. I could rebuild 4.3.1.alpha1 from scratch in the sage account but that would take several hours, by which time I would have gone home from where I cannot connect to this machine on port 8000. But I will do that before going home and can continue looking at this tomorrow. John 2010/1/12 William Stein <wst...@gmail.com>: > On Tue, Jan 12, 2010 at 4:05 AM, John Cremona <john.crem...@gmail.com> wrote: >> I'm running a server under user "sage" using a pool of users sage0, >> sage1 etc to run the worksheets. Sage 4.3 on 64-bit ubuntu. All >> works fine with normal Sage cells, but I get this error when I put >> %magma at the top of a new cell in a new worksheet: >> >> Cell contents: >> >> %magma >> 2+2; >> >> >> Output: >> >> Traceback (most recent call last): >> File "<stdin>", line 1, in <module> >> File "_sage_input_3.py", line 4, in <module> >> print _support_.syseval(magma, >> ur\u0027\u0027\u00272+2;\u0027\u0027\u0027, >> \u0027/home/sage/.sage/sage_notebook.sagenb/home/cremona/9/cells/1\u0027) >> File "", line 1, in <module> >> >> File >> "/usr/local/sage/sage-4.3/local/lib/python2.6/site-packages/sagenb-0.4.8-py2.6.egg/sagenb/misc/support.py", >> line 464, in syseval >> system.chdir(dir) > > I bet this is caused by changes in the notebook. Could you try > editing the file: > > /usr/local/sage/sage-4.3/local/lib/python2.6/site-packages/sagenb-0.4.8-py2.6.egg/sagenb/misc/support.py > > and replacing line 464 (the "system.chdir(dir)") by > > try: system.chdir(dir) > except: pass > > or -- simply delete the "system.chdir" line. > > and see what happens. Please report back. That will likely work, > in which case we'll do something like that in the notebook, though > better will be to correctly define dir (it is wrong right now). > Please report back. > >> File >> "/usr/local/sage/sage-4.3/local/lib/python2.6/site-packages/sage/interfaces/magma.py", >> line 905, in chdir >> magma.eval('ChangeDirectory("%s")'%dir) >> File >> "/usr/local/sage/sage-4.3/local/lib/python2.6/site-packages/sage/interfaces/magma.py", >> line 520, in eval >> raise RuntimeError, "Error evaluating Magma code.\nIN:%s\nOUT:%s"%(x, ans) >> RuntimeError: Error evaluating Magma code. >> IN:ChangeDirectory("/home/sage/.sage/sage_notebook.sagenb/home/cremona/9/cells/1"); >> OUT: >>>> ChangeDirectory("/home/sage/.sage/sage_notebook.sagenb/home/cremona/9/cells >> ^ >> Runtime error in 'ChangeDirectory': Cannot change directory to >> "/home/sage/.sage/sage_notebook.sagenb/home/cremona/9/cells/1" >> (Permission denied) >> >> Note that there is no error if I delete the first line ("%magma"). >> >> I noticed that some relevant files have the following permissions: >> >> s...@selmer:~/.sage/sage_notebook.sagenb/home/cremona/9$ ls -al >> /home/sage/.sage/sage_notebook.sagenb/home/cremona/9 >> total 24 >> drwxr-xr-x 4 sage sage 4096 Jan 12 12:01 . >> drwxr-xr-x 12 sage sage 4096 Jan 12 11:57 .. >> drwxr-xr-x 3 sage sage 4096 Jan 12 11:58 cells >> drwxrwxrwx 2 sage sage 4096 Jan 12 11:57 data >> -rw-r--r-- 1 sage sage 1280 Jan 12 12:01 worksheet.html >> -rw-r--r-- 1 sage sage 381 Jan 12 12:01 worksheet_conf.pickle >> >> s...@selmer:~/.sage/sage_notebook.sagenb/home/cremona/9$ ls -al >> /home/sage/.sage/sage_notebook.sagenb/home/cremona/9/cells >> total 12 >> drwxr-xr-x 3 sage sage 4096 Jan 12 11:58 . >> drwxr-xr-x 4 sage sage 4096 Jan 12 12:01 .. >> drwx------ 2 sage sage 4096 Jan 12 11:58 1 >> >> s...@selmer:~/.sage/sage_notebook.sagenb/home/cremona/9$ ls -al >> /home/sage/.sage/sage_notebook.sagenb/home/cremona/9/cells/1 >> total 8 >> drwx------ 2 sage sage 4096 Jan 12 11:58 . >> drwxr-xr-x 3 sage sage 4096 Jan 12 11:58 .. >> >> If the issue were that the worksheet is running under user sage0 while >> the files are all owned by the notebook process sage, which I don't >> believe is true, then the "%magma" would make no difference. >> >> This problem did not arise when I did not use the pool. And the >> machine does have magma installed! >> >> Any ideas? >> >> John >> >> -- >> To post to this group, send an email to sage-devel@googlegroups.com >> To unsubscribe from this group, send an email to >> sage-devel+unsubscr...@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/sage-devel >> URL: http://www.sagemath.org >> >> > > > > -- > William Stein > Associate Professor of Mathematics > University of Washington > http://wstein.org > > -- > To post to this group, send an email to sage-devel@googlegroups.com > To unsubscribe from this group, send an email to > sage-devel+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/sage-devel > URL: http://www.sagemath.org > >
-- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org