hopeless-dream

导航

解决ipython或jupeter中无法使用tab补全

ipython中无法使用tab补全,并且调用方法直接推出

报错

In [2]: help(open)
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/IPython/terminal/ptutils.py", line 113, in get_completions
    yield from self._get_completions(body, offset, cursor_position, self.ipy_completer)
  File "/usr/local/lib/python3.6/site-packages/IPython/terminal/ptutils.py", line 126, in _get_completions
    for c in completions:
  File "/usr/local/lib/python3.6/site-packages/IPython/core/completer.py", line 438, in _deduplicate_completions
    completions = list(completions)
  File "/usr/local/lib/python3.6/site-packages/IPython/core/completer.py", line 1818, in completions
    for c in self._completions(text, offset, _timeout=self.jedi_compute_type_timeout/1000):
  File "/usr/local/lib/python3.6/site-packages/IPython/core/completer.py", line 1862, in _completions
    full_text=full_text, cursor_line=cursor_line, cursor_pos=cursor_column)
  File "/usr/local/lib/python3.6/site-packages/IPython/core/completer.py", line 2030, in _complete
    cursor_pos, cursor_line, full_text)
  File "/usr/local/lib/python3.6/site-packages/IPython/core/completer.py", line 1374, in _jedi_matches
    text[:offset], namespaces, column=cursor_column, line=cursor_line + 1)
  File "/usr/local/lib/python3.6/site-packages/jedi/api/__init__.py", line 726, in __init__
    project=Project(Path.cwd()), **kwds)
TypeError: __init__() got an unexpected keyword argument 'column'

 

执行如下命令解决

pip3 install -U jedi==0.17.2 parso==0.7.1

 

posted on 2021-02-28 23:34  hopeless-dream  阅读(252)  评论(0编辑  收藏  举报