-
Notifications
You must be signed in to change notification settings - Fork 15
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
LD_LIBRARY_PATH is set within VSCode integrated terminal #46
Comments
Some more research revealed that the shell is launched by node-pty shipped with vscode-server and requiring nix-ld to run. I assume, when the the actual shell (in my case fish) is launched by an execve syscall, that the environment just persists. The workaround I am using for now is to |
I just came across this problem too ( Of course this is really only a workaround. The README mentions |
nix-ld-rs should fix this limitation |
https://github.com/nix-community/nix-ld-rs indeed says:
This sounds very promising. Thanks for letting us know! |
I just switched to nix-ld-rs and I'm still seeing |
I take it back. Today it's working correctly. I had tried completely shutting down VSCode and starting it back up yesterday and it was still working, but maybe it kept a server process around for a while, because today my environment looks fine. |
I am using nix-ld to run vscode-server on a nixos machine. Which works quite well, thanks!
I realized that within VSCode's integrated terminal LD_LIBRARY_PATH is set. This wasn't an issue, since NIX_LD was set to the system's LD anyways so most binaries continued to work.
However, it all broke down when using an old nixpkgs pin within a direnv environment. All binaries fail to launch with errors like:
Unsetting LD_LIBRARY_PATH within the terminal fixes the error.
I asume that somehow vscode-server stores the LD_LIBRARY_PATH variable and sets it on all child shells. I have yet to find a non-hacky way to get rid of the behaviour. Is there a way from nix-ld's side, to prevebt LD_LIBRARY_PATH to be propagated to vscode-servers child processes?
The text was updated successfully, but these errors were encountered: