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.

Language Server initialization failed

See original GitHub issue

When I open a python project, the python output console shows the language server failing to initialise.

The logs show vscode libraries being loaded from a Google Drive folder, which is managed by https://github.com/lra/mackup

Environment data

  • VS Code version: Version 1.25.1 (1.25.1)
  • Extension version (available under the Extensions sidebar): 2018.7.0
  • OS and version: OSX 10.13.6
  • Python version (& distribution if applicable, e.g. Anaconda): 2.7 and 3.6 (different projects)
  • Type of virtual environment used (N/A | venv | virtualenv | conda | …): pyenv-virtualenv + pipenv

Actual behavior

Language server fails to start.

Expected behavior

Language server starts.

Steps to reproduce:

  1. Open a python project

Logs

Output for Python in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python)

Starting Microsoft Python language server.
[Info  - 14:22:55] Created Microsoft.PythonTools.Interpreter.Ast.AstPythonInterpreter instance from Microsoft.PythonTools.Interpreter.Ast.AstPythonInterpreterFactory
[Error - 14:22:56] Server initialization failed.
  Message: Object reference not set to an instance of an object.
  Code: -32000 
[object Object]

Output from Console under the Developer Tools panel (toggle Developer Tools on under Help)

log.ts:171   ERR Object reference not set to an instance of an object.: Error: Object reference not set to an instance of an object.
    at new ResponseError (/Users/josh/Google Drive/Mackup/.vscode/extensions/ms-python.python-2018.7.0/node_modules/vscode-jsonrpc/lib/messages.js:46:28)
    at handleResponse (/Users/josh/Google Drive/Mackup/.vscode/extensions/ms-python.python-2018.7.0/node_modules/vscode-jsonrpc/lib/main.js:430:48)
    at processMessageQueue (/Users/josh/Google Drive/Mackup/.vscode/extensions/ms-python.python-2018.7.0/node_modules/vscode-jsonrpc/lib/main.js:258:17)
    at Immediate.<anonymous> (/Users/josh/Google Drive/Mackup/.vscode/extensions/ms-python.python-2018.7.0/node_modules/vscode-jsonrpc/lib/main.js:242:13)
    at runCallback (timers.js:672:20)
    at tryOnImmediate (timers.js:645:5)
    at processImmediate [as _immediateCallback] (timers.js:617:5)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
patryscommented, Jul 20, 2018

I think that’s a duplicate of #2017

0reactions
MikhailArkhipovcommented, Aug 9, 2018

@masat76 - most probably https://github.com/Microsoft/vscode-python/issues/2017. We should have insiders build with updated LS ready in a day or two. @d3r3kk FYI

Read more comments on GitHub >

github_iconTop Results From Across the Web

[SOLVED] OH and VScode: Server initialization failed - VS Code
Running OH 2.4.0 on a rPi3B VSC 1.37.1 on Win10 OH Extension: 0.5.1 When I start the OH workspace, the OUTPUT window in...
Read more >
Vivado 2021.1 stuck initializing language server - Xilinx Support
1) Delete the manifest.tcl file. 2) Start Vivado and open a project. 3) Let it freeze trying to open a source file. 4)...
Read more >
Julia Language Server initialization performance issue
Hello, I am new to Julia and using neovim in combination with julia-vim (syntax highlighting) and coc-julia (language server). , the time to ......
Read more >
VSCode can't start InterSystems Language Server
I can export classes, change them, save and import back to IRIS. But every time VSCode starts, the message "Request initialize failed with...
Read more >
Language Server Extension Guide - Visual Studio Code
Learn how to create Language Servers to provide rich language features in Visual Studio Code.
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