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.

lingering python jedi subprocesses from .vscode/extensions/ms-python

See original GitHub issue

Environment data

  • VS Code version: 1.55.2
  • OS and version: Ubuntu 20.04
  • Python version (& distribution if applicable, e.g. Anaconda): 3.6.6, 3.8.5
  • Type of virtual environment used (N/A | venv | virtualenv | conda | …): venv
  • Relevant/affected Python packages and their versions: jedi
  • Relevant/affected Python-related VS Code extensions and their versions: python-mscode
  • Value of the python.languageServer setting:

Expected behaviour

Remove the lingering subprocesses

Actual behaviour

VSCode leaves lingering jedi python subprocesses

Steps to reproduce:

  1. Open VSCode on some python project
  2. Quit VSCode
  3. ps aux | grep python -> seeing the lingering subprocess

ms-python-extensions

Logs

eleijon+ 1854483  0.0  0.0 266232 32212 ?        Rl   apr14   0:12 /bin/python3 /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/run-jedi-language-server.py
eleijon+ 1854502  0.0  0.0  37220 24432 ?        S    apr14   0:00 /bin/python3 /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp/jedi/inference/compiled/subprocess/__main__.py /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp 3.8.5
eleijon+ 1884925  0.0  0.3 922340 124748 ?       SNl  apr14   0:04 /usr/bin/python3 /usr/bin/update-manager --no-update --no-focus-on-map
eleijon+ 1911826 66.8  7.1 2687892 2311636 ?     Rl   apr14 764:31 /bin/python3 /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/run-jedi-language-server.py
eleijon+ 1911845  0.0  0.0  33596 20996 ?        S    apr14   0:00 /bin/python3 /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp/jedi/inference/compiled/subprocess/__main__.py /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp 3.8.5
eleijon+ 1912373 60.6  5.9 2297860 1941368 ?     Rl   apr14 693:37 /home/eleijonmarck/dev/hello/pipeline/.venv/bin/python /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/run-jedi-language-server.py
eleijon+ 1912406  0.0  0.0  42272 30916 ?        S    apr14   0:05 /home/eleijonmarck/dev/hello/pipeline/.venv/bin/python /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp/jedi/inference/compiled/subprocess/__main__.py /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp 3.6.6
eleijon+ 1916181 60.5  5.5 2178764 1819576 ?     Rl   apr14 688:51 /home/eleijonmarck/dev/hello/pipeline/.venv/bin/python /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/run-jedi-language-server.py
eleijon+ 1916245  0.0  0.0  31944 20564 ?        S    apr14   0:00 /home/eleijonmarck/dev/hello/pipeline/.venv/bin/python /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp/jedi/inference/compiled/subprocess/__main__.py /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp 3.6.6
eleijon+ 1916722  0.0  0.3 346516 113652 ?       Sl   apr14   0:28 /home/eleijonmarck/dev/hello/pipeline/.venv/bin/python /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/run-jedi-language-server.py
eleijon+ 1916745  0.0  0.0  41760 27852 ?        S    apr14   0:00 /home/eleijonmarck/dev/hello/pipeline/.venv/bin/python /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp/jedi/inference/compiled/subprocess/__main__.py /home/eleijonmarck/.vscode/extensions/ms-python.python-2021.3.680753044/pythonFiles/lib/jedilsp 3.6.6

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
karthiknadigcommented, Apr 15, 2021

@eleijonmarck can you try with the latest insiders and see if this still repros? You can always download and install latest insiders build form here https://pvsc.blob.core.windows.net/extension-builds/ms-python-insiders.vsix .

0reactions
eleijonmarckcommented, Jun 3, 2021

honestly, I do not know what happened. Either vs-code updated or vscode-python updated. But now the problem seems to have gone away

@karthiknadig Thank you for the help that you provided

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using Jedi — Jedi 0.18.2 documentation - Read the Docs
Jedi is can be used with a variety of plugins, language servers <language-servers> and other software. It is also possible to use Jedi...
Read more >
Is it possible to embed Jedi in an application on a system ...
My questions: Is it possible to get Jedi not to spawn subprocesses, and instead run its code inside the same instance of Python...
Read more >
Jedi does not use current interpreter · Issue #4504 - GitHub
Run VS Code with setting "python.pythonPath" pointing to a Python environment not installed on Windows. The environment is working, but it is ...
Read more >
subprocess — Subprocess management — Python 3.11.1 ...
Source code: Lib/subprocess.py The subprocess module allows you to spawn new processes, connect to their input/output/error pipes, and obtain their return ...
Read more >
jedi - PyPI
Jedi is a static analysis tool for Python that is typically used in IDEs/editors plugins. Jedi has a focus on autocompletion and goto...
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