Search code examples
ipythonreadlinesublimerepl

WARNING: Readline services not available or not loaded.AttributeError: 'module' object has no attribute 'set_completer_delims'


REPL run ipython an error occurred. WARNING: Readline services not available or not loaded.

Traceback (most recent call last):
  File "C:\Program Files\Sublime Text 3\Data\Packages/SublimeREPL/config/Python/ipy_repl.py", line 52, in <module>
    embedded_shell.initialize()
  File "<string>", line 2, in initialize
  File "D:\Python27\lib\site-packages\IPython\config\application.py", line 75, in catch_config_error
    return method(app, *args, **kwargs)
  File "D:\Python27\lib\site-packages\IPython\terminal\ipapp.py", line 332, in initialize
    self.init_shell()
  File "D:\Python27\lib\site-packages\IPython\terminal\console\app.py", line 114, in init_shell
    client=self.kernel_client,
  File "D:\Python27\lib\site-packages\IPython\config\configurable.py", line 337, in instance
    inst = cls(*args, **kwargs)
  File "D:\Python27\lib\site-packages\IPython\core\interactiveshell.py", line 524, in __init__
    self.init_completer()
  File "D:\Python27\lib\site-packages\IPython\terminal\console\interactiveshell.py", line 129, in init_completer
    self.Completer = ZMQCompleter(self, self.client, config=self.config)
  File "D:\Python27\lib\site-packages\IPython\terminal\console\completer.py", line 37, in __init__
    self.readline.set_completer_delims('\r\n')
AttributeError: 'module' object has no attribute 'set_completer_delims'

Solution

  • I experienced this problem whilst running ipython console in the WinPython distribution. In my case the problem was fixed by installing pyreadline:

    pip install pyreadline
    

    Hope this works for you too.