Python file is not running - Code-server: 3.10.1
OS/Web Information
- Web Browser: Edge
- Local OS: Linux - Ubuntu 20.04 LTS
- Remote OS: Ubuntu 20.04 LTS
- Remote Architecture: VM
code-server --version: 3.10.1 421237f499079cf88d68c02163b70e2b476bbb0d Latest
Steps to Reproduce
- Run a python file in terminal
Expected
It should run my python file.
Actual
- The terminal is not opening!
- Throwing two errors:
- command :
'python.execlnTerminal'not found - command :
'python.execlnTerminal-icon'not found
- command :
Logs
Screenshot

Notes
This issue can be reproduced in VS Code: Yes
It's possible this is because our Python extension is broken. Uninstalling Python and Jupyter and installing Python from Open VSX instead might work around the issue for now (the Python extension on Open VSX is bundled with Jupyter).
See https://github.com/cdr/code-server/issues/3364#issuecomment-840513845
I have exactly the same issue as you. But I figured it out that it was simply a bug of ms-python extension. Just choose an old version and hopefully the problem will be solved.
Interesting...I could not reproduce this issue locally. I'm using the Python extension v2021.5.842923320 with code-server 3.10.1 on macOS + Chrome.
Screenshot
https://user-images.githubusercontent.com/3806031/119380134-2b627380-bc75-11eb-9a51-8ef96213b92b.mov
I have exactly the same issue, with 3.10.1 and 3.10.2. It's not just for Python execution, but also when I try to select the interpreter, I have this error:
Command 'Python: Select Interpreter' resulted in an error (command 'python.setInterpreter' not found)
Also, I've manually installed the latest version of Python extension (that works on 3.10.0 and downwards), with the same result.
Interesting...I could not reproduce this issue locally. I'm using the Python extension v2021.5.842923320 with code-server 3.10.1 on macOS + Chrome.
Screenshot
Screen.Recording.2021-05-24.at.9.47.10.AM.mov
I have this same issue, appears to only be an issue when clicking the play button in the top right, if I type out my command as you did then it runs as expected.
I am a total novice so cannot speculate as to why this issue is arising, I am only using the platform currently as a learning tool.
I had the same issue after upgrading to 3.10.2. For me it turned out to be the version of Jupyter v2021.5.0 not working correctly.
After reverting to v2021.3.0 everything started working fine again. Maybe it is worth a try.
Heads up - I'm looking at Jupyter again and will try to land a fix soon, depending on how complex the bug is.
Workaround reported by @marcel-hamer does not work for me (but using 3.10.0, see below):
- with versions 3.10.1 and 3.10.2 I can no longer select the Python interpreter;
- then, with version 3.10.0, reverting to Jupyter v2021.3.0 has no impact
Actually, the problem is hard to bisect (for me). I've came across a working solution with 3.10.2, but after an un-recorded upgrade path... When trying to remove everything, including user .local settings and install from scratch, I cannot get any combination of code-server and Python/Jupyter extensions that works.
Hey there, I've pushed new versions of the extensions, can you please install ms-python.python 2021.5.842923320 and ms-toolsai.jupyter 2021.6.832593372 and report back?
PS: there appears to be an upstream bug that causes autocomplete to break (without Pylance, which we are not allowed to ship) with the LSP set to Default, so please change the language server to Jedi in the Python extension settings.
@ericct it's possible you were running into a similar bug to the one I ran into while diagnosing this - with the language server set to default, closing and reopening made autocomplete no longer work correctly.
Can you update both extensions, set the LSP to Jedi, and try again?
Hey there, I've pushed new versions of the extensions, can you please install ms-python.python 2021.5.842923320 and ms-toolsai.jupyter 2021.6.832593372 and report back?
For me this fixed the issue.
@ericct it's possible you were running into a similar bug to the one I ran into while diagnosing this - with the language server set to default, closing and reopening made autocomplete no longer work correctly.
Can you update both extensions, set the LSP to Jedi, and try again?
I've just updated the extensions with the versions mentioned and set LSP to Jedi: With interactive code or notebook, the Python environment starts correctly and I can run "Python: Select interpreter".
But then with interactive code and notebook, any cell with output will fail (Chunk load error / timeout behavior)
But everything seems to be OK so far with v3.10.2 👍
Hi !
Is it possible to download ms-python.python 2021.5.842923320 and ms-toolsai.jupyter 2021.6.832593372 offline ? I've triied to download these extensions but I get an error : cannot access extensions.coder.com because I'm in offline env.
Is where I've downloaded : https://sotnikov-link.github.io/get-vscode-extension-for-offline-install/
Is exists a simple way to download last working extensions for last code-server ?
Thanks !
We have some docs about installing extensions manually here but you do need to be online to download them. Once they're downloaded though, you should be fine.
Is exists a simple way to download last working extensions for last code-server
The latest version of code-server should work with the Python extension (just downloaded now). But the marketplace and code-server are decoupled meaning you can downgrade code-server but the marketplace will download the latest version of the extension. There is an option to download older versions of the extension but if you downgrade code-server, you'll have to test previous versions to see what works.

Thanks for your reply ! How can I export the .vsix file ? I need this to transfert the file to my offline env.
EDIT : I have always : cannot access extensions.coder.com when I use my .vsix file to my offline install.
Hmm...I think when extensions are installed, the .vsix files are unpacked 🤔 So you'd have to download outside of code-server.
You could talk directly to the open-vsx API. Example:
curl 'https://open-vsx.org/api/foam/foam-vscode' | jq '.files.download' | xargs curl --compressed -L -o foam.vsix
And then you'd have the .vsix file and you could put it on a USB drive or something to transfer to your offline env.
Thanks! In openvsx server, the python's version is 2020, is it possible to get the latest ? (https://open-vsx.org/extension/ms-python/python) Or maybe is not possible or 2020 is enough ?
It's difficult to manage an offline env ^^
Ah shoot...that's right. Hmm.. I am not sure how to get the latest 😅 cc @oxy or @code-asher - maybe they can help.
It's difficult to manage an offline env ^^
I can imagine! Props to you lol
Ah, right -
You first need to install ms-toolsai.jupyter before you install ms-python.python when you're installing offline.
What happens is that when you install Python, Jupyter is listed as a mandatory dependency, and by default VSCode will try and resolve that against the default gallery. But since the dependency isn't the other way around, installing Jupyter first and Python second should work!