-
Notifications
You must be signed in to change notification settings - Fork 282
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
Breakpoints fail to bind in Node 16 or Chrome 90 in functions with destructured arguments #1017
Comments
This looks like a bug in V8 that was fixed in Chrome 91. It seems that they fail to bind breakpoints in any async function that has destructured arguments. It should be fixed in Node.js once they pick up the latest V8 build. |
I'll add a warning if we detect usages of Node 16-16.2. Verifier: make sure the warning is shown and makes sense. |
Thanks for the reply! I'll hold out for a Node update. |
@connor4312 I saw that you added the warning for 16.2 but the issue is still present in 16.3. |
^ verification-found by @richardsimko . |
Please verify the warning is present; 16.3 was just released on Thursday and I don't plan to push candidate fixes for this (or future) releases. It's a helpful hint to exist, but Node will continue releasing updates and I will patch for them on our normal release cadence. |
@JacksonKearl it's only shown when launching Node. When attaching we don't get the version in the same way. |
Tried these launch configs and never saw a notification?
|
Hm, those should work. Can you stick a trace: true in |
Yea, I figured a popup might be too intrusive. If breakpoints aren't working, I think most users' first inclination will be to check the console for errors, so I figured it was a decent place for it. |
Fair enough. Though I cant shake that it might be nicer to assume Node.js 16.X broken until confirmed fixed versus constantly having folks who install the latest release be confused until we get to bumping our known-broken limit. |
I think this is the MR we're waiting for. |
What options do those of us that are running Mac with M1 chips and hence cannot downgrade to node 14 have? :D wait for the fix? Is there a workaround? Thanks! |
It works in Node 15 if that runs on M1. Otherwise I saw that the PR to upgrade V8 has been merged so I would presume it will be released in the next minor for 16. |
I can't seem to run v15 on mac M1. On every post I find online they say is as simple as |
Describe the bug
If a file contains two nested anonymous functions with parameters in Node 16 it's impossible to set a breakpoint on the inner function. Minimal example here: https://github.com/richardsimko/vscode-debugger-issues
if you run the code with
npm run start
and try to use any of the debug targets to attach to the process it becomes impossible to set a breakpoint on line 5 ofindex.js
.To Reproduce
Steps to reproduce the behavior:
git clone git@github.com:richardsimko/vscode-debugger-issues.git
npm run start
Log File
I've attached a log file of me launching the debug config, trying to add the breakpoint and quitting the debug config.
VS Code Version: 1.56.2
Additional context
Possibly related to using
type: module
, but I'm not sure. It works on any node versions <16 and I couldn't find anything specific to neither the debugger nor ESM in the patch notes.The text was updated successfully, but these errors were encountered: