Ask Your Question
1

How do I use Sloane's Encyclopedia on Sage Math Cloud?

asked 10 years ago

Peter Luschny gravatar image

updated 10 years ago

Calling SloaneEncyclopedia.install() (in a IPython notebook) gives the IOError "Connection refused".

Update: The error has changed. It is now

/usr/local/sage/sage-6.2.rc2/local/lib/python/os.pyc in makedirs(name, mode)
    155         if tail == curdir:           # xxx/newdir/. exists if xxx/newdir exists
    156             return
--> 157     mkdir(name, mode)
    158 
    159 def removedirs(name):

OSError: [Errno 13] Permission denied: '/usr/local/sage/sage-6.2.rc2/local/share/sloane'

Preview: (hide)

Comments

Projects by default now have a firewall that blocks most outgoing connections. Exactly what ip addresses does `SloaneEncyclopedia.install()` use? Maybe I could unblock it...

William Stein gravatar imageWilliam Stein ( 10 years ago )

FWIW, works fine in a local Sage Version 6.3.beta4.

rws gravatar imagerws ( 10 years ago )

rws, for a local Sage it works also for older versions. The issue is (perhaps was, William changed something, I have not yet tested it) in the Cloud.

Peter Luschny gravatar imagePeter Luschny ( 10 years ago )

@William Stein: Apparently oeis.org uses the ip 67.23.6.156, you could unblock that. Thanks!

slelievre gravatar imageslelievre ( 10 years ago )

1 Answer

Sort by » oldest newest most voted
0

answered 10 years ago

Peter Luschny gravatar image

In the file sage/databases/sloane.py replace in the code

def install(self, oeis_url="http://oeis.org/classic/stripped.gz", names_url="http://oeis.org/classic/names.gz", overwrite=False):

by

def install(self, oeis_url="http://oeis.org/stripped.gz", names_url="http://oeis.org/names.gz", overwrite=False):

In the documentation of the install function replace

- ``oeis_url`` - string (default: "http://www.research.att.com...")

by

 - ``oeis_url`` - string (default: "http://oeis.org...")

and replace

- ``names_url`` - string (default: "http://www.research.att.com...")

by

- ``names_url`` - string (default: "http://oeis.org...")

Reference: http://oeis.org/wiki/QandA_For_New_OE...

Preview: (hide)
link

Comments

This refers to https://github.com/sagemath/sagelib/blob/master/sage/databases/sloane.py By chance the next time I googled I got https://github.com/sagemath/sage/blob/064df9f25ec6d075add84200748ad9e770d0af21/src/sage/databases/sloane.py Here the definition of the install function is correct but not the documentation.

Peter Luschny gravatar imagePeter Luschny ( 10 years ago )

Thanks for pointing this out -- it is now tracked at http://trac.sagemath.org/ticket/10358

niles gravatar imageniles ( 10 years ago )

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 10 years ago

Seen: 637 times

Last updated: Jul 01 '14