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
debug list() command showing an extra }); at the end #9768
Comments
Looks like this is the area of interest, https://github.com/nodejs/node/blob/master/lib/_debugger.js#L1107. That is removing the module wrapper, looks like nothing removes the end of the module wrapper |
PR added: #9773 |
… list command When doing the list command using a number that is more than the amount lines in that files, ex: list(10), the ending of the Module wrapper was still showing. This removes that line. Fixes: nodejs#9768
… list command When doing the list command using a number that is more than the amount lines in that files, ex: list(10), the ending of the Module wrapper was still showing. This removes that line. Fixes: nodejs#9768
In Node.js 8.x, the output makes it more clear what's going on (specifically, that the contents of the file are wrapped in a function): $ node debug index2.js
(node:40275) [DEP0068] DeprecationWarning: `node debug` is deprecated. Please use `node inspect` instead.
< Debugger listening on ws://127.0.0.1:9229/f7cc0dbf-ae9a-43fa-be19-48505725769b
< For help see https://nodejs.org/en/docs/inspector
< Debugger attached.
Break on start in index2.js:1
> 1 (function (exports, require, module, __filename, __dirname) { console.log('debugger');
2
3 });
debug> Still an issue in v6.x (and probably v4.x, though). |
If I'm not wrong, this can be closed since the cli debugger is deprecated. |
Yep, we can close now. |
While debugging a very simple file(index.js), contents are:
and using the
node debug index.js
, i see this displayed:On line 3, there is a random
});
there. Don't know if this is a bug, or not.I thought maybe it was because the code is possibly being wrapped for execution, but running a
list(100)
or some other big number, shows the same thing.Obviously not a huge deal
The text was updated successfully, but these errors were encountered: