-
Notifications
You must be signed in to change notification settings - Fork 823
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
Running VSCode for Linux in WSL #2760
Comments
@therealkenc Has done a lot of investigating on this. Two recent comments by him that shed some light on why this is happening: FWIW in my time experimenting with running my own electron app on WSL, I believe I encountered the same event loop problem. Ultimately, the addition of setInterval(() => {}, 1); to the main process kept the event loop spinning in the background. I have no clue why that worked, however. Maybe someone could try plugging that line into a custom VSCode build to see if it works? |
Wait, so someone planned to close the issue in microsoft/vscode#13138 and link here because (s)he thought the issue had nothing to do with VSCode and instead a problem with WSL. I followed the link here only to find out what the next step is probably a PR to Microsoft/vscode ??? |
@khuongduybui The one-liner I recommended would be a hack that could help verify the underlying event loop issue in running VS Code (if it even works). This is 100% a problem with WSL, as is elaborated on in the comments I linked. |
ok thanks for the clarification. |
@khuongduybui Yeh sorry for not being clearer, based on what @therealkenc and @Harangue have found out, it looks like the event loop locks up on WSL where this doesn't happen in "clean" Linux. |
This is awesome, check it out @commanderturner 😃
…On Wed, 20 Dec 2017, 5:16 am Duy K. Bui, ***@***.***> wrote:
Guys, I just updated to 17063. Code is running now, wow!
[image: 2017-12-20]
<https://user-images.githubusercontent.com/831343/34192252-eab8dbb0-e51a-11e7-9f87-acaf8a3f17f4.png>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#2760 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ABC6ZaFztWNRpoGjUFRUMjUiPL7EhqTmks5tCJgXgaJpZM4RFc0F>
.
|
Do I close this issue now or wait until it's in the mainstream release? |
I think it's safe to say you can close it but @therealkenc or somebody will need to add the "fixed in insiders build" tag. Question is if the fix for this can be backported to 16299. |
Hey guys (espeically @khuongduybui ), been trying to set this up as well. Few questions:
|
Thanks for all the investigation! I've verified that this works with non-insiders Code, on Windows Insider build 17063. I'm running VCXsrv, multiwindow, no special configuration. I added the
I installed Code (non-insiders) using the commands from above:
Running Code is slow, but it works. A few times Code failed to launch completely and I had to kill it using Task Manager. As expected, it can create and edit files in your Linux paths. |
Interestingly, this has stopped working for me again now 😢 with a Pulseaudio issue:
Up to now (for the last 19 days) this was working almost flawlessly and was my main coding environment. |
Marking this a discussion only thread again. |
Ok, it's fixed again in insiders (Windows insiders that is) |
Hello all, I have followed your exact instructions and have got to this point:
I get the same error with: |
@kinmanlam Sorry, I missed out the instruction to start the DBUS service as I have that running in WSL from startup, I've added this to the notes now too but here's the command for reference.
|
I have following the instructions on this issue, and from clean wsl ubuntu installed and display=:0 exported. I am able to run xeyes, firefox, gedit, etc... when i start code or code-insiders, code just runs in the background without any windows GUI starting.
If I understand correctly, I need to install windows insiders build to run code is wsl or there another solution to get the gui up and running. |
No that's, the solution you need the windows insiders build presently until
its included in the next windows release.
Ed
…On Sat, 17 Feb 2018, 7:45 am alexanderdevm, ***@***.***> wrote:
I have following the instructions on this issue, and from clean wsl ubuntu
installed and display=:0 exported. I am able to run xeyes, firefox, gedit,
etc...
when i start code or code-insiders, code just runs in the background
without any windows GUI starting.
code --verbose -s --disable-gpu
[364:0217/023541.956859:WARNING:audio_manager.cc(295)] Multiple instances
of AudioManager detected
[364:0217/023541.956913:WARNING:audio_manager.cc(254)] Multiple instances
of AudioManager detected
code --verbose [428:0217/024131.817155:WARNING:audio_manager.cc(295)]
Multiple instances of AudioManager detected
[428:0217/024131.817256:WARNING:audio_manager.cc(254)] Multiple instances
of AudioManager detected
[456:0217/024132.114776:ERROR:gl_implementation.cc(245)] Failed to load
libGL.so.1: libGL.so.1: cannot open shared object file: No such file or
directory [456:0217/024132.116547:ERROR:gpu_child_thread.cc(324)] Exiting
GPU process due to errors during initialization
If I understand correctly, I need to install windows insiders build to run
code is wsl or there another solution to get the gui up and running.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#2760 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ABC6ZYaIV0eCI7oBySm89eV7Q3_1Y2u4ks5tVoOBgaJpZM4RFc0F>
.
|
@khuongduybui hi,can you tell me which way that you get the 17063 insider build?thanks! |
@Xixi20160512 I just did this to test the solution. My PC is currently downloading version 17074.1002 EDIT: |
Ran course. |
Hello, it seems that of today (Windows 10 build 17730.1000 + Code Insiders 1.26.0), the settings are a little different than the one you provided to make it works. I didn't need to make these 2 instructions :
And I needed to install the following : Also, to get rid of the error I've put these at the end of my
Hope this helps! 😄 I still have a lot of these warnings :
Does anyone have any idea if it's solvable? |
I don't quite understand why this issue was closed. It's not working for me. |
This is working for me, thanks! I've written a more detailed and beginners-proof version of the installation steps you provided here. Still, VS Code is blurry on High DPI monitors. Anyone knows how to fix that? |
That Gist you linked is a 404 @fedme 😢 |
Updated the link, sorry for that! |
I cannot get this to work. I have followed the instructions, but nonetheless, Here is the output. Seems to be multiple errors, but I am having trouble tracking down how to fix any of them. Help would be appreciated.
|
Windows 10 Pro |
Also don't export The
You're better off on 17763 aka 1809 for unrelated reasons but it should fly alright on 17134. If you subsequently get the |
@therealkenc after a restart, it is now working. Though, I still see the following error, even though
Another red herring perhaps? |
Hard to say. Something thinks that missing |
I'm creating a new issue for this as the previous two got way off track talking about the windows version of VS Code from WSL.
I now have VS Code for Ubuntu installed in the Ubuntu WSL in windows at version 1.19.0-insider
To get to the point at which I am at, install an XServer for windows, I use VcXsrv with the following settings:
Then, in WSL you need at least the creators update, do the following:
Install the required libs
Add VS Code repository
Install VS Code Insiders (and code itself if you like)
Set the environmental paramaters
NOTE At this point you need the DBUS service to be running (thanks @kinmanlam, I forgot :) ):
Attempt to run VS Code Insiders with verbose logging so you see any issues
I now have only two warnings about multiple instances of AudioManager being detected and no errors. When clicking exit in XServer, it reports that there are clients connected so VS Code seems to be attaching to the XServer instance however the app does not display in the XServer window.
As there are no further errors in the verbose output I am stuck as to where to go next to debug this, are there any other logs/output sources I can look into?
Related:
Running VS Code native in WSL
Support launching VS Code from Bash on Ubuntu on Windows
@commanderturner
The text was updated successfully, but these errors were encountered: