Skip to content

startDebugging method in vscode still return true even when the build fails #54214

@rodrigovaras

Description

@rodrigovaras

Live share extension on the host side is using the startDebugging method to launch a debug configuration remotely. As part of step it will eventually need to invoke a task to build that could fail, the problem is that the API will not report 'false' value during the invocation.
Extract of the code here:

const result = await vscode.debug.startDebugging(folders ? folders[0] : undefined, debugConfiguration);
if (!result) {
// THIS code almost never get invoked....
throw new Error(Failed to launch debug configuration:${debugConfiguration.name});
}

we would like a better mechanism to know what really happen in our launch invocation.
Maybe knowing:

  • If the build task was cancelled
  • task failed
  • Debug configuration is invalid
  • Failure to launch

Adding a new richer method may be better...

Metadata

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugdebugDebug viewlet, configurations, breakpoints, adapter issuesverifiedVerification succeeded

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions