On Apr 5, 7:20 am, Nikos Apostolakis <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I am trying to use sage in a cgi script and every time I try to
> import the sage libraries I keep getting the following error
>
> -------- 8< --------
> Traceback (most recent call last):
>   File "/usr/local/include/sage-2.10.2/local/bin/sage-eval", line 4,
>   in <module>
>     from sage.all import *
>   File
>   
> "/usr/local/include/sage-2.10.2/local/lib/python2.5/site-packages/sage/all.py",
>   line 53, in <module>
>     from sage.misc.all       import *         # takes a while
>   File
>   
> "/usr/local/include/sage-2.10.2/local/lib/python2.5/site-packages/sage/misc/all.py",
>   line 1, in <module>
>     from misc import (alarm, ellipsis_range, ellipsis_iter, srange,
>   xsrange, sxrange, getitem,
>   File
>   
> "/usr/local/include/sage-2.10.2/local/lib/python2.5/site-packages/sage/misc/misc.py",
>   line 83, in <module>
>     os.makedirs(DOT_SAGE)
>   File "/usr/local/include/sage-2.10.2/local/lib/python2.5/os.py",
>   line 172, in makedirs
>     mkdir(name, mode)
> OSError: [Errno 13] Permission denied: '/.sage/'
> -------- >8 --------
>
> I guess that at some point sage tries to create a directory at "/"
> and it doesn't have permisssion to.  

Hi Nick,

Sage checks for the exitence of $HOME/.sage and if it doesn't exist
creates it. In your case $HOME seems to be empty.

> Is this a bug?  Any workarounds?

It isn't a bug. To fix this we need to know more about your setup,
i.e. which user the webserver runs as, which webserver you are using
and so on. I am not an expert on those things related to Sage, but
somebody else should be able to take it from there.

> TIA,
> Nikos

Cheers,

Michael
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to