question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

7.18.0 crash when autocompleting

See original GitHub issue

With version 7.18.0, when I press TAB for autocompletion, IPython hangs and then crashes This doesn’t happen with 7.17.0

Linux

$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.1 LTS
Release:	20.04
Codename:	focal

Reproduction

$ ipython
Python 3.8.2 (default, Jul 16 2020, 14:00:26)
Type 'copyright', 'credits' or 'license' for more information
IPython 7.18.0 -- An enhanced Interactive Python. Type '?' for help.

In [1]: import networkx as nx                                                                         

In [2]: g = nx.Graph()                                                                                

In [3]: g                                                                                             
Traceback (most recent call last):
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/terminal/ptutils.py", line 113, in get_completions
    yield from self._get_completions(body, offset, cursor_position, self.ipy_completer)
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/terminal/ptutils.py", line 126, in _get_completions
    for c in completions:
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/core/completer.py", line 438, in _deduplicate_completions
    completions = list(completions)
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/core/completer.py", line 1819, in completions
    for c in self._completions(text, offset, _timeout=self.jedi_compute_type_timeout/1000):
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/core/completer.py", line 1876, in _completions
    signature = _make_signature(jm)
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/core/completer.py", line 991, in _make_signature
    return '(%s)'% ', '.join([f for f in (_formatparamchildren(p) for signature in completion.get_signatures()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/core/completer.py", line 991, in <listcomp>
    return '(%s)'% ', '.join([f for f in (_formatparamchildren(p) for signature in completion.get_signatures()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/core/completer.py", line 991, in <genexpr>
    return '(%s)'% ', '.join([f for f in (_formatparamchildren(p) for signature in completion.get_signatures()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/core/completer.py", line 968, in _formatparamchildren
    raise ValueError('Jedi function parameter description have change format.'
ValueError: Jedi function parameter description have change format.Expected "param ...", found 'def __new__'".

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/juanpi/virtual_enviroments/memnet/bin/ipython", line 8, in <module>
    sys.exit(start_ipython())
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/__init__.py", line 126, in start_ipython
    return launch_new_instance(argv=argv, **kwargs)
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/traitlets/config/application.py", line 664, in launch_instance
    app.start()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/terminal/ipapp.py", line 356, in start
    self.shell.mainloop()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/terminal/interactiveshell.py", line 564, in mainloop
    self.interact()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/terminal/interactiveshell.py", line 547, in interact
    code = self.prompt_for_code()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/terminal/interactiveshell.py", line 473, in prompt_for_code
    text = self.pt_app.prompt(
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/shortcuts/prompt.py", line 994, in prompt
    return self.app.run(set_exception_handler=set_exception_handler)
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/application/application.py", line 811, in run
    return loop.run_until_complete(
  File "/usr/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
    return future.result()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/application/application.py", line 778, in run_async
    return await _run_async2()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/application/application.py", line 766, in _run_async2
    await self.cancel_and_wait_for_background_tasks()
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/application/application.py", line 867, in cancel_and_wait_for_background_tasks
    await task
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/buffer.py", line 1854, in new_coroutine
    await coroutine(*a, **kw)
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/buffer.py", line 1683, in async_completer
    async for completion in self.completer.get_completions_async(
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/completion/base.py", line 269, in get_completions_async
    async for completion in completer.get_completions_async(
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/prompt_toolkit/completion/base.py", line 196, in get_completions_async
    for item in self.get_completions(document, complete_event):
  File "/home/juanpi/virtual_enviroments/memnet/lib/python3.8/site-packages/IPython/terminal/ptutils.py", line 116, in get_completions
    print_tb(e)
  File "/usr/lib/python3.8/traceback.py", line 53, in print_tb
    print_list(extract_tb(tb, limit=limit), file=file)
  File "/usr/lib/python3.8/traceback.py", line 72, in extract_tb
    return StackSummary.extract(walk_tb(tb), limit=limit)
  File "/usr/lib/python3.8/traceback.py", line 347, in extract
    for f, lineno in frame_gen:
  File "/usr/lib/python3.8/traceback.py", line 312, in walk_tb
    yield tb.tb_frame, tb.tb_lineno
AttributeError: 'ValueError' object has no attribute 'tb_frame'

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:11
  • Comments:17 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
l3shi1Lcommented, Dec 31, 2020

Just downgrade jedi module to version 0.17.2 pip install ipython pip install jedi==0.17.2 Tested python3.6 python3.7 python3.8 in Win10. Maybe works for you.

2reactions
Carreaucommented, Aug 29, 2020

I’ve reverted some of the jedi changes and published a 7.18.1, still not sure what is hapeening.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Release 7.18.0 The IPython Development Team
IPython Documentation, Release 7.18.0 ... Fix Bug where type? would crash IPython. ... #3798: IPython 0.12.1 Crashes on autocompleting ...
Read more >
Ipython: Autocompletion crashes session ('sys' is not defined)
When I try to use iPython's auto-completion, the session crashes with the following error: Traceback (most recent call last): File ...
Read more >
Firebase JavaScript SDK Release Notes - Google
Fixed a bug that caused crashes in Cloud Storage, Cloud Functions for Firebase Client SDK, and Realtime Database when using the all-in-one firebase...
Read more >
DIM Changes
The loadout name editor will no longer offer system autocomplete. ... Fixed a crash when trying to assign deprecated Combat Style mods.
Read more >
Excel crashes when clicking the autocomplete formula
Hello, I would like to seek for help regarding my issue on MS Excel wherein it keeps freezing and crashing when I click...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found