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

EH debugging: use massaged launch for attach #31659

Closed
isidorn opened this issue Jul 28, 2017 · 3 comments
Closed

EH debugging: use massaged launch for attach #31659

isidorn opened this issue Jul 28, 2017 · 3 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug debug Debug viewlet, configurations, breakpoints, adapter issues verified Verification succeeded

Comments

@isidorn
Copy link
Contributor

isidorn commented Jul 28, 2017

As Andre pointed out:

@isidorn in EH debugging, the launchRequest starts the extension host (via VS Code) but the DA does not connect (aka "attach") to it (in normal "node" debugging the DA connects to the launched debuggee automatically).

Instead VS Code knows when the EH is ready and then broadcasts an event that you will pick up and issue the missing "attach" request for it. This is basically the same sequence as the "reload EH window" sequence.

For the "attach" request that you issue in response to the broadcast, you use the initial "launch" configuration and just change the "request" attribute from "launch" to "attach".
Since the initial "launch" config uses the type "extensionHost", the "attach" uses that too.

The fix is to remember the massaged launch config (that got the type "extensionHost2"), and create the "attach" config based on this.

@isidorn isidorn added the debug Debug viewlet, configurations, breakpoints, adapter issues label Jul 28, 2017
@isidorn isidorn added this to the August 2017 milestone Jul 28, 2017
@isidorn isidorn self-assigned this Jul 28, 2017
@isidorn
Copy link
Contributor Author

isidorn commented Aug 3, 2017

Code pointer

@weinand the issue here is that the terminate event sometimes comes before the attach. So in order to get the massaged config I would have to remember all the configs for all the sessions that ever existed. Which I can do, but maybe a nicer alternative would be for me to ask the extension to massage the config again. Thoughts?

fyi @roblourens

@isidorn isidorn added the under-discussion Issue is under discussion for relevance, priority, approach label Aug 3, 2017
@isidorn isidorn modified the milestones: September 2017, August 2017 Aug 30, 2017
@weinand
Copy link
Contributor

weinand commented Sep 5, 2017

Most likely this is not an issue anymore since we no longer rewrite the type for EH debugging from extensionHost to extensionHost2

@isidorn
Copy link
Contributor Author

isidorn commented Sep 8, 2017

This is actually fixed via 9eec2b4
Now we are remembering the configs of all processes, including if they get massaged

@isidorn isidorn closed this as completed Sep 8, 2017
@isidorn isidorn added bug Issue identified by VS Code Team member as probable bug and removed under-discussion Issue is under discussion for relevance, priority, approach labels Sep 8, 2017
@roblourens roblourens added the verified Verification succeeded label Sep 27, 2017
@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 17, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug debug Debug viewlet, configurations, breakpoints, adapter issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

3 participants