Skip to content
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

Fixes to run dart and flutter vscode extensions #6044

Merged
merged 10 commits into from
Sep 4, 2019
Prev Previous commit
Next Next commit
[debug] ignore additional breakpoints returned by setBreakpoints re…
…quest

otherwise it fails `undefined` and swallows updates for other breakpoints

Signed-off-by: Anton Kosyakov <anton.kosyakov@typefox.io>
  • Loading branch information
akosyakov committed Sep 4, 2019
commit 73cca79b408acfbc5f3b40aa9e4d05e01e28a283
7 changes: 6 additions & 1 deletion packages/debug/src/browser/debug-session.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,12 @@ export class DebugSession implements CompositeTreeElement {
sourceModified,
breakpoints: enabled.map(({ origin }) => origin.raw)
});
response.body.breakpoints.map((raw, index) => enabled[index].update({ raw }));
response.body.breakpoints.map((raw, index) => {
// node debug adapter returns more breakpoints sometimes
if (enabled[index]) {
enabled[index].update({ raw });
}
});
} catch (error) {
// could be error or promise rejection of DebugProtocol.SetBreakpointsResponse
if (error instanceof Error) {
Expand Down