lundi 1 juin 2015

Ipython : Installation error, unable to find _sqlite.so

On trying to install ipython for Python3.4 I get a message that it is already installed.

pip3 install ipython
Requirement already satisfied (use --upgrade to upgrade): ipython in /usr/local/lib/python3.4/site-packages

But when I try to run it with ipython3 notebook I get all this:

Traceback (most recent call last):
  File "/usr/local/bin/ipython3", line 11, in <module>
sys.exit(start_ipython())
  File "/usr/local/lib/python3.4/site-packages/IPython/__init__.py", line 120, in start_ipython
return launch_new_instance(argv=argv, **kwargs)
  File "/usr/local/lib/python3.4/site-packages/IPython/config/application.py", line 573, in launch_instance
app.initialize(argv)
  File "<string>", line 2, in initialize
  File "/usr/local/lib/python3.4/site-packages/IPython/config/application.py", line 75, in catch_config_error
return method(app, *args, **kwargs)
  File "/usr/local/lib/python3.4/site-packages/IPython/terminal/ipapp.py", line 321, in initialize
super(TerminalIPythonApp, self).initialize(argv)
  File "<string>", line 2, in initialize
  File "/usr/local/lib/python3.4/site-packages/IPython/config/application.py", line 75, in catch_config_error
return method(app, *args, **kwargs)
  File "/usr/local/lib/python3.4/site-packages/IPython/core/application.py", line 369, in initialize
self.parse_command_line(argv)
  File "/usr/local/lib/python3.4/site-packages/IPython/terminal/ipapp.py", line 316, in parse_command_line
return super(TerminalIPythonApp, self).parse_command_line(argv)
  File "<string>", line 2, in parse_command_line
  File "/usr/local/lib/python3.4/site-packages/IPython/config/application.py", line 75, in catch_config_error
return method(app, *args, **kwargs)
  File "/usr/local/lib/python3.4/site-packages/IPython/config/application.py", line 471, in parse_command_line
return self.initialize_subcommand(subc, subargv)
  File "<string>", line 2, in initialize_subcommand
  File "/usr/local/lib/python3.4/site-packages/IPython/config/application.py", line 75, in catch_config_error
return method(app, *args, **kwargs)
  File "/usr/local/lib/python3.4/site-packages/IPython/config/application.py", line 402, in initialize_subcommand
subapp = import_item(subapp)
  File "/usr/local/lib/python3.4/site-packages/IPython/utils/importstring.py", line 42, in import_item
module = __import__(package, fromlist=[obj])
  File "/usr/local/lib/python3.4/site-packages/IPython/html/notebookapp.py", line 67, in <module>
from .services.sessions.sessionmanager import SessionManager
  File "/usr/local/lib/python3.4/site-packages/IPython/html/services/sessions/sessionmanager.py", line 7, in <module>
import sqlite3
  File "/usr/local/lib/python3.4/sqlite3/__init__.py", line 23, in <module>
from sqlite3.dbapi2 import *
  File "/usr/local/lib/python3.4/sqlite3/dbapi2.py", line 27, in <module>
from _sqlite3 import *
ImportError: No module named '_sqlite3'

Assuming that the last line is the most important

ImportError: No module named '_sqlite3'

I tried to install all sorts of dependencies for it:

apt-get install sqlite3 libsqlite3-dev

When I tried installing Pysqlite via pip3 install pysqlite :

Collecting pysqlite
  Using cached pysqlite-2.6.3.tar.gz
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 20, in <module>
      File "/tmp/pip-build-ggtq7_wu/pysqlite/setup.py", line 85
        print "Is sphinx installed? If not, try 'sudo easy_install sphinx'."
                                                                       ^
    SyntaxError: Missing parentheses in call to 'print'

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-ggtq7_wu/pysqlite

However Sphinx is already installed. I even reinstalled it.

pip3 install sphinx
Requirement already satisfied (use --upgrade to upgrade): sphinx in /usr/local/lib/python3.4/site-packages
Requirement already satisfied (use --upgrade to upgrade): Jinja2>=2.3 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): snowballstemmer>=1.1 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): docutils>=0.11 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): babel>=1.3 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): sphinx-rtd-theme<0.2,>=0.1 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): alabaster<0.8,>=0.7 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): Pygments>=2.0 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): six>=1.4 in /usr/local/lib/python3.4/site-packages (from sphinx)
Requirement already satisfied (use --upgrade to upgrade): markupsafe in /usr/local/lib/python3.4/site-packages (from Jinja2>=2.3->sphinx)
Requirement already satisfied (use --upgrade to upgrade): pytz>=0a in /usr/local/lib/python3.4/site-packages (from babel>=1.3->sphinx)

Hence I have not been able to resolve it because evidently that file _sqlite3.so which should be in /usr/local/lib/python3.4/lib-dynload does not exist and I cannot find a way to install it.

Aucun commentaire:

Enregistrer un commentaire