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

Debugger doesn't exit after program run #5709

Closed
SetTrend opened this issue Mar 15, 2016 · 10 comments
Closed

Debugger doesn't exit after program run #5709

SetTrend opened this issue Mar 15, 2016 · 10 comments
Labels
duplicate Issues and PRs that are duplicates of other issues or PRs.

Comments

@SetTrend
Copy link

When debugging the following simple project (only a gulpfile.js) in VS Code, the debugger doesn't exit after the last line of code has been executed:

Gulp4ParallelTest.zip

The VS Code team suggests that this is a problem in the Node runtime.

I feel it's quite confusing not to safely know whether all threads/processes in a program have finished or not when debugging.

@mscdex
Copy link
Contributor

mscdex commented Mar 15, 2016

What node version are you using?

@Fishrock123
Copy link
Contributor

What command are you running to start it?

Can you please post the example to something like gist or another pasting service? (Also please try to make a test-case that does not require npm modules to reproduce.)

@SetTrend
Copy link
Author

I have lost my VM over the weekend so I can't tell. But I'm sure it was Node 4.

@SetTrend
Copy link
Author

For details on how I started the Node debugger, please refer to the issue I cross-referenced above:

microsoft/vscode#3339

@jasnell
Copy link
Member

jasnell commented Mar 23, 2016

Unfortunately this is not quite enough information to go off of. I know it may be difficult to do so, but we'll need a reproduceable test case that demonstrates the issue before we can adequately diagnose the problem.

@SetTrend
Copy link
Author

Of course, I apprehend. Yesterday I was able to setup a new VM with latest versions of all my development software. I'll create a test case over the weekend and keep you updated.

@SetTrend
Copy link
Author

I'm running the latest safe Node version: 4.4.0.

Here's a log of the debugging session I started:

PS D:\Documents\Visual Studio-Projekte\VS Code\Gulp4ParallelTest> node debug .\gulpfile.js
< Debugger listening on port 5858
debug> . ok
break in D:\Documents\Visual Studio-Projekte\VS Code\Gulp4ParallelTest\gulpfile.js:2
  1 ///<reference path="headers/chalk/chalk.d.ts"/>
> 2 "use strict";
  3
  4 let gulp = require("gulp");
debug> cont
debug>

As you can see, the debugger doesn't quit after the last thread has ended running.

Here's the same code, debugged using a GUI (i.e. Visual Studio Code):
node debugger

@MylesBorins
Copy link
Contributor

I'm going to investigate this week

@MylesBorins MylesBorins self-assigned this Mar 27, 2016
@SetTrend
Copy link
Author

Great. Thanks!

@MylesBorins
Copy link
Contributor

I'm going to close this as a duplicate of #1788

I'll be continuing my investigation in that thread

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate Issues and PRs that are duplicates of other issues or PRs.
Projects
None yet
Development

No branches or pull requests

5 participants