sage crashes at notebook function

Bug #339218 reported by Matthias Blaicher
22
This bug affects 3 people
Affects Status Importance Assigned to Milestone
sagemath (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: sagemath

SAGE crashes when using the notebook function either at CLI or as command line parameter.

$ sage -notebook
----------------------------------------------------------------------
| SAGE Version 3.0.5, Release Date: 2008-07-11 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------

Please wait while the SAGE Notebook server starts...
...
The notebook files are stored in: /home/mabl/.sage//sage_notebook
**************************************************
* *
* Open your web browser to http://localhost:8000 *
* *
**************************************************
/usr/lib/python2.6/dist-packages/twisted/persisted/sob.py:12: DeprecationWarning: the md5 module is deprecated; use hashlib instead
  import os, md5, sys
/usr/lib/python2.6/dist-packages/twisted/python/filepath.py:12: DeprecationWarning: the sha module is deprecated; use the hashlib module instead
  import sha
Traceback (most recent call last):
  File "/usr/lib/python2.6/dist-packages/twisted/application/app.py", line 694, in run
    runApp(config)
  File "/usr/lib/python2.6/dist-packages/twisted/scripts/twistd.py", line 23, in runApp
    _SomeApplicationRunner(config).run()
  File "/usr/lib/python2.6/dist-packages/twisted/application/app.py", line 411, in run
    self.application = self.createOrGetApplication()
  File "/usr/lib/python2.6/dist-packages/twisted/application/app.py", line 494, in createOrGetApplication
    application = getApplication(self.config, passphrase)
--- <exception caught here> ---
  File "/usr/lib/python2.6/dist-packages/twisted/application/app.py", line 505, in getApplication
    application = service.loadApplication(filename, style, passphrase)
  File "/usr/lib/python2.6/dist-packages/twisted/application/service.py", line 390, in loadApplication
    application = sob.loadValueFromFile(filename, 'application', passphrase)
  File "/usr/lib/python2.6/dist-packages/twisted/persisted/sob.py", line 214, in loadValueFromFile
    exec fileObj in d, d
  File "sage_notebook/twistedconf.tac", line 9, in <module>
    import sage.server.notebook.notebook
exceptions.ImportError: No module named sage.server.notebook.notebook

Failed to load application: No module named sage.server.notebook.notebook

Traceback (most recent call last):
  File "/usr/lib/sagemath/local/bin/sage-notebook", line 16, in <module>
    notebook(port=8000)
  File "/usr/lib/python2.5/site-packages/sage/server/notebook/notebook_object.py", line 143, in __call__
    return self.notebook(*args, **kwds)
  File "/usr/lib/python2.5/site-packages/sage/server/notebook/run_notebook.py", line 271, in notebook_twisted
    return run(port)
  File "/usr/lib/python2.5/site-packages/sage/server/notebook/run_notebook.py", line 255, in run
    raise socket.error
socket.error

ProblemType: Crash
Architecture: i386
DistroRelease: Ubuntu 9.04
ExecutablePath: /usr/lib/sagemath/local/bin/sage-notebook
InterpreterPath: /usr/bin/python2.5
Package: sagemath 3.0.5dfsg-2ubuntu1 [modified: usr/share/sagemath/data/extcode/sagebuild/build/compilers/__init__.pyc usr/share/sagemath/data/extcode/sagebuild/build/compilers/all.pyc usr/share/sagemath/data/extcode/sagebuild/build/compilers/cython.pyc usr/share/sagemath/data/extcode/sagebuild/build/compilers/gcc.pyc usr/share/sagemath/data/extcode/sagebuild/build/__init__.pyc usr/share/sagemath/data/extcode/sagebuild/build/all.pyc usr/share/sagemath/data/extcode/sagebuild/build/action.pyc usr/share/sagemath/data/extcode/sagebuild/build/taskmanager.pyc usr/share/sagemath/data/extcode/sagebuild/build/optionmanager.pyc usr/share/sagemath/data/extcode/sagebuild/build/enviroment.pyc usr/share/sagemath/data/extcode/sagebuild/build/filewalker.pyc usr/share/sagemath/data/extcode/sagebuild/build/compiler.pyc usr/share/sagemath/data/extcode/sagebuild/build/config.pyc usr/share/sagemath/data/extcode/sagebuild/build/dependencies.pyc]
ProcCmdline: python /usr/lib/sagemath/local/bin/sage-notebook
ProcEnviron:
 SHELL=/bin/bash
 PATH=(custom, no user)
 LANG=en_US.UTF-8
PythonArgs: ['/usr/lib/sagemath/local/bin/sage-notebook']
SourcePackage: sagemath
Title: sage-notebook crashed with error in run()
Uname: Linux 2.6.28-8-generic i686
UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare

Revision history for this message
Matthias Blaicher (blaicher) wrote :
Revision history for this message
Thomas Folz-Donahue (eigenlambda) wrote :

I have the same bug. Apparently, sage likes to run this command:
cmd = 'sage -twistd --pidfile="%s"/twistd.pid -ny "%s"/twistedconf.tac'%
(directory, directory)

and if it returns 256, raise socket.error .

I don't know what 256 is supposed to mean.

Revision history for this message
Tim Abbott (tabbott) wrote :

The problem here is this:

exceptions.ImportError: No module named sage.server.notebook.notebook

Sage is only built for python 2.5, but the notebook is being run with the default system python (python 2.6), which doesn't work. Some work will be required to fix the package to force the use a python version the Sage library is built for when you run "sage -notebook".

Changed in sagemath:
status: New → Confirmed
Revision history for this message
Tim Abbott (tabbott) wrote :

I'm uploading sagemath 3.0.5dfsg-3 to Debian shortly that will fix this bug (and various others as well).

Since 3.0.5dfsg-3 uses the new boost library -dev package names, it should be possible to just sync sagemath once it hits sid.

Revision history for this message
Anders Kaseorg (andersk) wrote :

The sync request is bug #344903.

Revision history for this message
Matthias Blaicher (blaicher) wrote :

The new version 3.0.5dfsg-3 fixes the problem for me. Thank you

Changed in sagemath:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.