The Python extension v2024.14.0 fails to start with VSCode 1.89.1. The error message mentions: Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1.
Steps to reproduce:
Install VSCode version 1.89.1
Open VSCode and install the Python extension. For me, v2024.14.0 was the version that was installed. I did not specifically select this version.
Create a new Python file and realize that the Python extension is not working
Output for Python in the Output panel (View→Output, change the drop-down the upper-right of the Output panel to Python)
```
024-10-10 10:30:33.711 [info] Telemetry level is off
2024-10-10 10:30:33.711 [info] Experiments are disabled, only manually opted experiments are active.
2024-10-10 10:30:33.711 [info] Python interpreter path: C:\Program Files\Python311\python.exe
2024-10-10 10:30:34.064 [error] [
'Failed to start language server, Class name = h, completed in 354ms, has a falsy return value, Arg 1: , Arg 2: {"id":"C:\\\\PROGRAM FILES\\\\PYTHON311\\\\PYTHON.EXE","sysPrefix":"C:\\\\Program Files\\\\Python311","envType":"Global","envName":"","envPath":"","path":"C:\\\\Program Files\\\\Python311\\\\python.exe","architecture":3,"sysVersion":"3.11.9 (tags/v3.11.9:de54cf5, Apr 2 2024, 10:12:12) [MSC v.1938 64 bit (AMD64)]","version":{"raw":"3.11.9","major":3,"minor":11,"patch":9,"build":[],"prerelease":["final","0"]},"companyDisplayName":"PythonCore","displayName":"Python 3.11.9 64-bit","detailedDisplayName":"Python 3.11.9 64-bit"}, Arg 3: {"documentSelector":[{"scheme":"file","language":"python"},{"scheme":"untitled","language":"python"},{"scheme":"vscode-notebook","language":"python"},{"scheme":"vscode-notebook-cell","language":"python"},{"scheme":"vscode-interactive-input","language":"python"}],"synchronize":{"configurationSection":["python","jupyter.runStartupCommands"]},"outputChannel":{"name":"Python Language Server","logLevel":3},"revealOutputChannelOn":4,"initializationOptions":{"experimentationSupport":true,"trustedWorkspaceSupport":true},"middleware":{"serviceContainer":{"container":{"options":{"autoBindInjectable":false,"defaultScope":"Transient","skipBaseClassChecks":true},"id":0,"_bindingDictionary":{"_map":{}},"_snapshots":[],"_middleware":null,"_activations":{"_map":{}},"_deactivations":{"_map":{}},"parent":null,"_metadataReader":{},"_moduleActivationStore":{"_map":{}}}},"serverVersion":"2024.8.2","lastCaptured":{},"nextWindow":0,"eventCount":0,"workspace":{},"connectedPromise":{"scope":null,"_resolved":false,"_rejected":false,"_promise":{}},"notebooks":{},"eventName":"LANGUAGE_SERVER.REQUEST"}}, Return Value: undefined',
[Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
]
2024-10-10 10:30:34.066 [error] [
'Starting language server, Class name = d, completed in 358ms, has a falsy return value, , Return Value: undefined',
[Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
2024-10-10 10:30:34.066 [error] Failure during activation. [Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
2024-10-10 10:30:34.066 [error] sendStartupTelemetry() failed. [Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
```
Extension version: 2024.14.0
VS Code version: Code 1.89.1 (dc96b837cf6bb4af9cd736aa3af08cf8279f7685, 2024-05-07T05:13:33.891Z)
OS version: Windows_NT x64 10.0.22621
Modes:
Python version (& distribution if applicable, e.g. Anaconda): 3.11.9
Type of virtual environment used (e.g. conda, venv, virtualenv, etc.): Global
Value of the python.languageServer setting: Default
Type: Bug
Behaviour
The Python extension v2024.14.0 fails to start with VSCode 1.89.1. The error message mentions:
Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
.Steps to reproduce:
Additional information
I believe this issue is caused by a mismatch of the version specification between the Python extension and
vscode-languageclient
. The Python extension version 2024.14.0 is compatible to"vscode": "^1.89.0-20240415"
(see here: https://github.com/microsoft/vscode-python/blob/v2024.14.0/package.json#L48). Meanwhile, the dependency vscode-languageclient is specified as"vscode-languageclient": "^10.0.0-next.12"
(https://github.com/microsoft/vscode-python/blob/v2024.14.0/package-lock.json#L36)However, vscode-languageclient 10.0.0-next.12 has a different VSCode version compatibility:
"vscode": "^1.91.0"
(https://github.com/microsoft/vscode-languageserver-node/blob/release/client/10.0.0-next.12/client/package.json#L8). Due to this discrepancy, I believe that either the version of the vscode-languageclient dependency or the VSCode version specification of the Python extension v2024.14.0 needs to be adjusted.Diagnostic data
Output for
Python
in theOutput
panel (View
→Output
, change the drop-down the upper-right of theOutput
panel toPython
)``` 024-10-10 10:30:33.711 [info] Telemetry level is off 2024-10-10 10:30:33.711 [info] Experiments are disabled, only manually opted experiments are active. 2024-10-10 10:30:33.711 [info] Python interpreter path: C:\Program Files\Python311\python.exe 2024-10-10 10:30:34.064 [error] [ 'Failed to start language server, Class name = h, completed in 354ms, has a falsy return value, Arg 1:, Arg 2: {"id":"C:\\\\PROGRAM FILES\\\\PYTHON311\\\\PYTHON.EXE","sysPrefix":"C:\\\\Program Files\\\\Python311","envType":"Global","envName":"","envPath":"","path":"C:\\\\Program Files\\\\Python311\\\\python.exe","architecture":3,"sysVersion":"3.11.9 (tags/v3.11.9:de54cf5, Apr 2 2024, 10:12:12) [MSC v.1938 64 bit (AMD64)]","version":{"raw":"3.11.9","major":3,"minor":11,"patch":9,"build":[],"prerelease":["final","0"]},"companyDisplayName":"PythonCore","displayName":"Python 3.11.9 64-bit","detailedDisplayName":"Python 3.11.9 64-bit"}, Arg 3: {"documentSelector":[{"scheme":"file","language":"python"},{"scheme":"untitled","language":"python"},{"scheme":"vscode-notebook","language":"python"},{"scheme":"vscode-notebook-cell","language":"python"},{"scheme":"vscode-interactive-input","language":"python"}],"synchronize":{"configurationSection":["python","jupyter.runStartupCommands"]},"outputChannel":{"name":"Python Language Server","logLevel":3},"revealOutputChannelOn":4,"initializationOptions":{"experimentationSupport":true,"trustedWorkspaceSupport":true},"middleware":{"serviceContainer":{"container":{"options":{"autoBindInjectable":false,"defaultScope":"Transient","skipBaseClassChecks":true},"id":0,"_bindingDictionary":{"_map":{}},"_snapshots":[],"_middleware":null,"_activations":{"_map":{}},"_deactivations":{"_map":{}},"parent":null,"_metadataReader":{},"_moduleActivationStore":{"_map":{}}}},"serverVersion":"2024.8.2","lastCaptured":{},"nextWindow":0,"eventCount":0,"workspace":{},"connectedPromise":{"scope":null,"_resolved":false,"_rejected":false,"_promise":{}},"notebooks":{},"eventName":"LANGUAGE_SERVER.REQUEST"}}, Return Value: undefined',
[Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
]
2024-10-10 10:30:34.066 [error] [
'Starting language server, Class name = d, completed in 358ms, has a falsy return value, , Return Value: undefined',
[Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
2024-10-10 10:30:34.066 [error] Failure during activation. [Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
2024-10-10 10:30:34.066 [error] sendStartupTelemetry() failed. [Error: The language client requires VS Code version ^1.91.0 but received version 1.89.1
at P.checkVersion (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2307252)
at new P (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:2306957)
at Object.createClient (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:52239)
at _0x500d80 (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:214371)
at async _0x5446db (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:218069)
at async _0x1d21da._startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:167360)
at async _0x1d21da._createNewRequest (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166885)
at async _0x1d21da._enqueueRequestAndWaitForRun (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:166089)
at async _0x1d21da.startClient (c:\Users\myuser\.vscode\extensions\ms-python.vscode-pylance-2024.8.2\dist\extension.bundle.js:1:165605)
at async h.start (c:\Users\myuser\.vscode\extensions\ms-python.python-2024.14.0-win32-x64\out\client\extension.js:2:39659)]
```
Extension version: 2024.14.0 VS Code version: Code 1.89.1 (dc96b837cf6bb4af9cd736aa3af08cf8279f7685, 2024-05-07T05:13:33.891Z) OS version: Windows_NT x64 10.0.22621 Modes:
python.languageServer
setting: DefaultUser Settings
``` languageServer: "Pylance" ```
Installed Extensions
|Extension Name|Extension Id|Version| |---|---|---| |JavaScript Debugger|ms-vscode.js-debug|1.89.0| |JavaScript Debugger Companion Extension|ms-vscode.js-debug-companion|1.1.2| |Pylance|ms-python.vscode-pylance|2024.8.2| |Python|ms-python.python|2024.14.0| |Python Debugger|ms-python.debugpy|2024.8.0| |Table Visualizer for JavaScript Profiles|ms-vscode.vscode-js-profile-table|1.0.9|System Info
|Item|Value| |---|---| |CPUs|Intel(R) Xeon(R) Platinum 8462Y+ (4 x 2800)| |GPU Status|2d_canvas: enabledcanvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled| |Load (avg)|undefined| |Memory (System)|16.00GB (4.69GB free)| |Process Argv|| |Screen Reader|no| |VM|100%|