Skip to content

Commit

Permalink
Merge pull request #12207 from aiguofer/fix_jedi_deprecations
Browse files Browse the repository at this point in the history
Bump jedi to at least 0.16.0 and fix deprecated function usage
  • Loading branch information
Carreau committed Mar 27, 2020
2 parents c926ce5 + 1e79c16 commit fe0ab8b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions IPython/core/completer.py
Expand Up @@ -988,7 +988,8 @@ def _make_signature(completion)-> str:
"""

return '(%s)'% ', '.join([f for f in (_formatparamchildren(p) for p in completion.params) if f])
return '(%s)'% ', '.join([f for f in (_formatparamchildren(p) for signature in completion.get_signatures()
for p in signature.defined_names()) if f])

class IPCompleter(Completer):
"""Extension of the completer class with IPython-specific features"""
Expand Down Expand Up @@ -1398,7 +1399,7 @@ def _jedi_matches(self, cursor_column:int, cursor_line:int, text:str):
if not try_jedi:
return []
try:
return filter(completion_filter, interpreter.completions())
return filter(completion_filter, interpreter.complete())
except Exception as e:
if self.debug:
return [_FakeJediCompletion('Oops Jedi has crashed, please report a bug with the following:\n"""\n%s\ns"""' % (e))]
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Expand Up @@ -184,7 +184,7 @@

install_requires = [
'setuptools>=18.5',
'jedi>=0.10',
'jedi>=0.16',
'decorator',
'pickleshare',
'traitlets>=4.2',
Expand Down

0 comments on commit fe0ab8b

Please sign in to comment.