Repository navigation
Pressing tab key to complete a method name causes traceback (jedi, Python 3.14) #14927
Copy link
Copy link
Closed
Closed
Copy link
Labels
Description
If I press the tab key on this line:
In [5]: pc._value_to_db
This is for pip version 25.1.1 and in Python 3.14.
The same version of pip works fine in Python 3.13.
I get this:
Traceback (most recent call last):
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/jedi/cache.py", line 110, in wrapper
return dct[key]
~~~^^^^^
KeyError: ((), frozenset())
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/parso/grammar.py", line 252, in load_grammar
return _loaded_grammars[path]
~~~~~~~~~~~~~~~~^^^^^^
KeyError: '/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/parso/python/grammar314.txt'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/parso/grammar.py", line 255, in load_grammar
with open(path) as f:
~~~~^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/parso/python/grammar314.txt'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/IPython/core/completer.py", line 3496, in _complete
result = matcher(context)
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/IPython/core/completer.py", line 2352, in _jedi_matcher
matches = self._jedi_matches(
cursor_column=context.cursor_position,
cursor_line=context.cursor_line,
text=context.full_text,
)
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/IPython/core/completer.py", line 2406, in _jedi_matches
interpreter = jedi.Interpreter(text[:offset], namespaces)
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/jedi/api/__init__.py", line 741, in __init__
super().__init__(code, environment=environment, project=project, **kwds)
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/jedi/api/__init__.py", line 119, in __init__
self._inference_state = InferenceState(
~~~~~~~~~~~~~~^
project, environment=environment, script_path=self.path
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/jedi/inference/__init__.py", line 91, in __init__
self.grammar = environment.get_grammar()
~~~~~~~~~~~~~~~~~~~~~~~^^
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/jedi/cache.py", line 112, in wrapper
result = method(self, *args, **kwargs)
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/jedi/api/environment.py", line 42, in get_grammar
return parso.load_grammar(version=version_string)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/cnobile/.virtualenvs/nc3.14/lib/python3.14/site-packages/parso/grammar.py", line 264, in load_grammar
raise NotImplementedError(message)
NotImplementedError: Python version 3.14 is currently not supported.
If you suspect this is an IPython 9.3.0 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:
%config Application.verbose_crash=True
Activity
krassowski commentedon Jun 25, 2025
Python 3.14 has not been released yet, nor the
parsowith support for Python 3.14 grammar. In the meantime you can use IPython with jedi disabled:krassowski commentedon Jun 25, 2025
Related upstream:
cnobile2012 commentedon Jun 25, 2025
Thanks for the workaround, I have two big projects, one is already on PyPi.
I'm trying to get ahead of the curve and get the API and App working with Python 3.14.
If you want to close this issue, go ahead and close it.
[-]Pressing tab key to complete a method name causes traceback.[/-][+]Pressing tab key to complete a method name causes traceback (jedi, Python 3.14)[/+]krassowski commentedon Aug 25, 2025
Parso
v0.8.5has been released recently - https://github.com/davidhalter/parso/releases/tag/v0.8.5 - which allows IPython jedi-based completer to work on Python 3.14 - closing.cnobile2012 commentedon Nov 9, 2025
I just updated my virtual environment. It now has IPython 9.7.0.
The problem still exists with the same traceback.
Python 3.14.0 (main, Oct 7 2025, 16:05:28) [GCC 13.3.0]
Type 'copyright', 'credits' or 'license' for more information
IPython 9.7.0 -- An enhanced Interactive Python. Type '?' for help.
Tip:
?alone on a line will brings up IPython's helpkrassowski commentedon Nov 9, 2025
You need to install latest jedi/parso
cnobile2012 commentedon Nov 9, 2025
Shouldn't that be a dependency for ipython and installed automatically?
Who would know unless they read this issue?
aklaver commentedon Dec 31, 2025
Agreed. I just installed ipython==9.8.0 and had to do a search to find this issue and find out out I had to separately upgrade jedi and parso. If you don't want to support the implicit dependencies then you need to change the config defaults to exclude them e.g. make %config IPCompleter.use_jedi = False the default. Otherwise make them explicit dependencies and upgrade with the ipython upgrade.