-
Notifications
You must be signed in to change notification settings - Fork 30.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to debug extension, warning message: "Plugin host did not start in 10 seconds" #4308
Comments
What version of node do you have? Do you have the same version on the system where it works and where it does not work. |
Yes, I was using nvm and tried different version of node. I tried with the same version as the one where it worked and even with the same version it was still not working on my machine. |
@narf the node version makes no difference in this case because the extension host is always using the node that is included in electron. |
Yeah, that's what I had in mind. I just tried to change it out of despair. |
I am running into this as well. Any guidance?
|
@chuckries does this happen all the time? |
I downloaded the insiders build and am not seeing the same issue from there. I think somehow my install of the public VS Code has been put in a bad state. |
@bpasero is there a simple way to increase the timeout on your side? |
I don't think it's a matter of the timeout. Something is hung. |
@chuckries does the launch config have a 'preLaunchTask'? If yes, could you try whether disabling it makes a difference? |
There is no preLaunchTask, I am using the default configuration for "Launch Extension":
|
I am able to F5 my extension just fine from the insiders build of Code but not from the public build. Uninstalling has no effect. Is there an AppData folder or something equivalent I can wipe out? |
I was finally able get past this by uninstalling Code then manually deleting |
I had that on my Linux Ubuntu 14.04.3 x64. I have fixed with the following steps:
sudo apt purge visual-studio-code
find ~ -name '*vscode*'
find /usr -name '*vscode*' |
@KalitaAlexey does this mean you have uninstalled and then installed VS Code again and now extension debugging works fine? |
@weinand Yes. |
@KalitaAlexey thanks for trying this. I still have no clue why this problem occurs and why it can be solved by reinstalling VS Code. @bpasero do you have an explanation? |
@weinand It happens to me after I tried VSCode for insiders and then installed VSCode 1.0. |
@weinand - I am seeing this issue with VSCode and the insiders build on Mac. First it only affected my insiders build install but later it started causing the regular build to require a break point. I've tried reinstalling Node, deleting vscode and any references to it but nothing worked so far. Are there any recommendations for doing a full clean of all dependencies to resolve this issue? It's a known error message in VSCode - does anyone know the cause / fix? Thanks. |
I'm also having a problem with this warning. I've installed VSCode from AUR on Arch Linux and tried create simple hello-world plugin. Also even though it's reported as a warning, VSCode doesn't seem to load my plugin at all. |
I got this problem too. Tried to clean up and reinstall, like mentioned before, but without success. This is with 1.7.1 on Win10, with a HelloWorld extension (neither ts or js variants work). There are zombie code.exe processes left behind, too. |
I'm also having a problem with this warning. In addition to this, there are also some warnings 'Couldn't find message for key node.xxx.xxx' |
I'm also having the same problem with this warning, i tried vscode 1. 8, 1.7, 1.6 and 1.5, every version debug failed. |
I tried the language server example and had this same problem. My steps are: git clone https://github.com/Microsoft/vscode-languageserver-node-example.git
cd client
npm install
code-insiders .
cd ../server
npm install
code-insiders .
Doing the same instructions with |
@andy-hanson this is an issue in Insiders build. Fix is adding a |
@andy-hanson I've fixed the launch configuration of the server in the "vscode-languageserver-node-example" repo. Please try again with the latest launch.json and let me know whether that fixes the problem. |
@weinand Thanks! It works after pulling in that change. |
Any progress on this? It is quite unnerving to have to debug by building a vsix, installing it and using the developer tools. Even if uninstalling and cleaning vscode and node would help, it's still not something one would like to do often. The extension host doesn't start. Can I debug that somehow? |
@vladdu since I do not have any details about your setup and the reproducible steps, I have no idea what problem you are experiencing. I suggest that you create a new bug with details about your setup and the reproducible steps. |
Sorry, there is a comment from november where I mention I have the same problem as the OP: when trying to launch and debug an extension, the extension host doesn't start and there is a timeout. Actually, it may start and hang, because there are zombie code.exe processes afterwards. I am now using 1.9 and also the insiders version, with the same result. Cleaning up as someone suggested didn't help. I want to help finding the problem, please guide me. |
@vladdu I asked for a separate issue because I cannot follow all the various threads that appear in an issue over the course of a year. 95% of all "me too" comments end up in being different issues (and only appeared to be similar on the surface). To your problem: could you quickly try to create a new VS Code extension with the yeoman generator and see whether you can run this from VS Code successfully? With this we could find out whether the problem you are seeing is a problem of your VS Code installation or whether it is a problem with your specific extension. Just follow the steps in the documentation until you've reached the last step of this section: https://code.visualstudio.com/docs/extensions/example-hello-world#_running-your-extension. |
Sure, sorry again, I use the github UI so all history is there. I created a hello world extension and the host still hangs. A difference is that now there is a "STOPPED on first line for debugging" message that I didn't see before - but there is a debugger attached (that isn't stopped) so I guess the communication fails somehow? I can see the "hello world" command, but it does nothing. |
So something with your setup is broken. We are not aware of any issues in that area on Windows (and I cannot reproduce the problem with VS Code 1.9.1 on Windows 10). Can you try this:
|
I tried this all before, but I did it again now:
I am running Win10 build 15031, if that might make a difference. I tried on different machines, works ok. |
@vladdu so you are saying that you see the issue only on one machine? |
Yes, I can see it on only my PC. I tried otherwise on both Win7 and Win10 (though not an insiders build) and it worked. I tried with different versions of nodejs. The process started with ""C:\Program Files (x86)\Microsoft VS Code\Code.exe" --nolazy --debug-brk=42930 "c:\Program Files (x86)\Microsoft VS Code\resources\app\out\bootstrap" --type=extensionHost" seems to hang, and it remains as a zombie after shutting down the editor. Is there a way to find out what it is waiting for? |
I got the problem today on a Win7 machine too, with a fresh install of vscode insiders. Then I installed the stable version and it started working for both versions. Weird! |
I've tried to mitigate the problem by only starting the extension process with In addition I've added a new trace flag 'eh'. If you see the problem again, please add a |
The change will appear in the next Insider release (probably on Monday). |
Thanks! Now this is an interesting fact: my insiders installation just got updated to commit 50f8848 and, surprise!, it now works. Unfortunately, I don't know what was my previous version, it would have been interesting to find what was wrong. edit: maybe it was the update of node-debug to 1.0.12? |
I've just experienced this issue on Linux, elementary os. I have tried rebooting Linux and reinstalling it with the method described near the top of the thread. I can provide the specific events leading up to recognising the issue. The extensionHost kept failing but I wasn't getting anything from the debugger, I opened the project on my windows machine and I had a coding issue which now outputted into the debugger. I fixed the issue and pushed to the repo, booted up into Linux to retry the extension with the code fix and didn't make any difference. It's not much different from the others claims. I haven't installed the insiders build and am running the latest version of vscode. Adding
I should mention that the extension was booting and tracing messages to the debugger even with the |
I've had the same issue. My solution was to turn off the proxy I was behind. Oddly, once I got it to run once, I can turn on the proxy again and things work. I'm not sure why this happens. Looking at the verbose trace, all So it seems that it was blocked network traffic that messed up things. Practically following the official guide as of yesterday. OS: Mac 10.12.6 Using the following lunch config (with verbose trace):
Here is the debug console output (Note the last line:
|
Steps to Reproduce:
The text was updated successfully, but these errors were encountered: