Skip to content

DebugAdapterExecutable does not support passing shell: true so .bat-based debug adapters are broken in current Insiders #224184

@DanTup

Description

@DanTup

In current Insiders (and presumably the upcoming release), spawning a .bat file on Windows without shell: true fails due to a breaking change in NodeJS:

https://nodejs.org/en/blog/vulnerability/april-2024-security-releases-2

It is important to note that there has been a breaking change for Windows users who utilize child_process.spawn and child_process.spawnSync. Node.js will now error with EINVAL if a .bat or .cmd file is passed to child_process.spawn and child_process.spawnSync without the shell option set.

It appears that there's no way to signal this to DebugAdapterExecutable and therefore any .bat-based debug adapters launched this way fail in current Insiders (and will presumably fail in stable soon).

Could shell: bool? be added to DebugAdapterExecutableOptions? I don't know enough to contribute this, but this seems quite important.

Metadata

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugcandidateIssue identified as probable candidate for fixing in the next releasedebugDebug viewlet, configurations, breakpoints, adapter issuesverifiedVerification succeeded

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions