-
Notifications
You must be signed in to change notification settings - Fork 29.3k
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
VSCode 1.54.1 breaks spawned processes with cwd option #118267
Comments
We just released an update to VS Code Insiders that has a fix for this issue. Please try it out and let us know. |
@deepak1556 thanks I tested with: Version: 1.55.0-insider (Universal) And the problem persists. With my mentioned test case I'm now getting EPIPE instead of EBADF:
|
I tested this a bit more and another variant that I have found work is when you now specify the full path to the script (despite the cwd option being set correctly). If the full path is not specified I will get ENOENT as if the file didn't exist (maybe cwd is not propagated properly)? |
To be more descriptive here is a test case: Given this foo.sh file (marked as executable) that is saved at #!/bin/bash
echo "called" >> /tmp/debugout Trying to execute the following statements in the debug console while debugging VSCode insiders (same version as noted above):
|
Thanks for the test case, @jeremie-stripe I tried your test case with node
|
And I think more specifically our case is the following because we use subpaths to reference our scripts: Node 10.16.0:
VSCode Insiders debug console:
|
Thanks for clarifying, can confirm the regression. |
Looking forward to seeing this bug fixed! This bug has Stripe engineering stuck on 1.53 since it impacts so many of our extensions and configurations; one common pattern in our setup is using shell scripts to wrap other tools to set them up properly for our dev environment. |
Fixed with https://domoreexp.visualstudio.com/Teamspace/_git/electron-build/pullrequest/344238, pending new builds. |
Fix didn't account for some edge cases on the failure path and introduced regression #122661. Reopening for next iteration. |
This turned out to be a bug in the Have resorted to use |
@deepak1556 thanks for figuring it out! I just tested with the latest insiders version (version info below) and I can confirm that our workloads are now properly working again!
|
Steps to Reproduce:
Does this issue occur when all extensions are disabled?: No
We run a few extensions (including an LSP server) which essentially spawn an external process executing shell wrapper scripts and attempts to manipulate its standard IO.
Since upgrading to 1.54.1 we have noticed a strange behavior where when writing to the external process stdin we get
EBADF
error. This seems specifically to only occur when attempting to execute shell script directly as when we modify the spawn (or similar functions) to invoke the script viabash
directly it works fine.This is illustrated by the following test cases executed while debugging VSCode:
Where
wrapper.sh
ultimately willexec
the rest of the command line.The text was updated successfully, but these errors were encountered: