Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ipython: OperationalError: disk I/O error

Tags:

ipython

I was running ipython successfully on fedora 18 until now: I'm getting the following exception when trying to launch it:

Traceback (most recent call last):
  File "/usr/bin/ipython", line 9, in <module>
    load_entry_point('ipython==1.1.0', 'console_scripts', 'ipython')()
  File "/usr/lib/python2.7/site-packages/IPython/__init__.py", line 118, in start_ipython
    return launch_new_instance(argv=argv, **kwargs)
  File "/usr/lib/python2.7/site-packages/IPython/config/application.py", line 544, in launch_instance
    app.initialize(argv)
  File "<string>", line 2, in initialize
  File "/usr/lib/python2.7/site-packages/IPython/config/application.py", line 89, in catch_config_error
    return method(app, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/IPython/terminal/ipapp.py", line 323, in initialize
    self.init_shell()
  File "/usr/lib/python2.7/site-packages/IPython/terminal/ipapp.py", line 339, in init_shell
    ipython_dir=self.ipython_dir, user_ns=self.user_ns)
  File "/usr/lib/python2.7/site-packages/IPython/config/configurable.py", line 349, in instance
    inst = cls(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/IPython/terminal/interactiveshell.py", line 320, in __init__
    **kwargs
  File "/usr/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 456, in __init__
    self.init_history()
  File "/usr/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 1487, in init_history
    self.history_manager = HistoryManager(shell=self, parent=self)
  File "/usr/lib/python2.7/site-packages/IPython/core/history.py", line 481, in __init__
    self.new_session()
  File "<string>", line 2, in new_session
  File "/usr/lib/python2.7/site-packages/IPython/core/history.py", line 65, in needs_sqlite
    return f(self, *a, **kw)
  File "/usr/lib/python2.7/site-packages/IPython/core/history.py", line 500, in new_session
    self.session_number = cur.lastrowid
OperationalError: disk I/O error

If you suspect this is an IPython bug, please report it at:
    https://github.com/ipython/ipython/issues
or send an email to the mailing list at [email protected]

You can print a more detailed traceback right now with "%tb", or use "%debug"
to interactively debug it.

Extra-detailed tracebacks for bug-reporting purposes can be enabled via:
    c.Application.verbose_crash=True

I tried to upgrade ipython to the latest version using pip, which did not help. Any solution or workaround is very much welcomed.

like image 937
Kludge Avatar asked Dec 06 '25 14:12

Kludge


1 Answers

IPython store history in a profile generally in ~/.ipython/profile_default/history.sqlite. There seem to be a disk error reading/writting to it. Check the permissions of the file/folders, if necessary delete the file.

like image 170
Matt Avatar answered Dec 09 '25 14:12

Matt



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!