-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Use Inspector instead of Legacy Debugger #285
Conversation
- Change Node 6.10 to use inspector debugging instead of legacy debugging
- Correct commands for node 6.10
- Don't overwrite headers
The legacy debugger in VSCode is useless as breakpoints are not working. Please merge this pull request as soon as possible. |
Could you update the README to reflect this required change too? Once that's added i'm happy to merge this in and get it included in the next release. Thanks! |
FYI - this is an important fix for my team as well - we use the debugger extensively. It is currently broken. Any movement on this would be greatly appreciated :). Thanks so much. |
- Updated VSCode launch config - Added note about detaching debugger
@PaulMaddox updated README |
Thanks @charsleysa! |
There seems to be an issue with this PR - when i'm testing it, turning on debugging doesn't halt execution - it should automatically halt on the first line of code so you can attach the debugger. I'll do some more testing later in the week to try and see what's up. |
Hello, were you able to resolve the issue with the PR? is this item fixed in the develop branch? |
I'm also having an issue with this PR/commit. It looks like Because of this, IDEs can't know when the debugger should detach. Is the note in the README suggesting that the user needs to manually detach the debugger upon program completion? This feels hackish. @PaulMaddox is there a certain fix you implemented to get it to halt execution? Or was there a change you made in the IDE plugin? |
I'm also curious, what caused the legacy debugger to break in VSCode? Was it working at some point and then it was broken by a change in SAM Local? |
FYI – After applying latest VSCode updates, the debugger (Legacy) is now working again with SAM local – I’m guessing changes to VSCode broke it, then they fixed it.
From: Brady Dowling
Sent: Wednesday, March 28, 2018 3:09 PM
To: awslabs/aws-sam-local
Cc: singulli1; Manual
Subject: Re: [awslabs/aws-sam-local] Use Inspector instead of Legacy Debugger(#285)
I'm also curious, what caused the legacy debugger to break in VSCode? Was it working at some point and then it was broken by a change in SAM Local?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
Ah that makes sense. Perhaps there should be an environment variable that allows you to override the run command altogether. I added an environment variable to allow for additional debugger args but replacing the command altogether may be preferable. This could potentially future proof SAM Local from breaking changes or needs like this from other services or IDEs. If a certain IDE breaks or requires certain arguments, you can just pass that environment variable and override the whole run command. |
Changes NodeJS 6.10 runtime debugging to use Inspector instead of Legacy Debugging.
A minor breaking change as debug tools need to have their config updated to use the Inspector protocol.
e.g. for VSCode inside launch.json you change
"protocol": "legacy",
to"protocol": "inspector",