-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Add support for lifecycleManagedByParent. #11751
Add support for lifecycleManagedByParent. #11751
Conversation
Forwards lifecycle events to parent session where applicable and changes the behavior of compound sessions to behave same way. Contributed on behalf of ST Microelectronics Signed-off-by: Thomas Mäder <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I noticed some issue related to parent and compound session management: When terminating a child session which has lifecycleManagedByParent
, the corresponding parent session is correctly terminated. However, when the parent session is part of a compound session, only the parent session is terminated, not the whole compound. The following screencap demonstrates this effect:
2022-10-13.14-56-48.mp4
VSCode correctly terminates the whole compound session in that case.
Signed-off-by: Thomas Mäder <[email protected]>
@msujew could you have another look, please? |
I verified that the code correctly walks upward to the compound configuration an that it terminates all root sessions from there. I was able to reproduce the case where terminating the back end by hand would leave child sessions behind, but not reliably. Looks to me like it's some kind of timing issue that IMO is unrelated to the change at hand. |
Hmh....turns out the "currentSession" management in the UI is completely off: the session being terminated is not what's selected in the UI. Debugging. |
Some more debugging shows that the "Launch Browser Frontend" sessions has a child session which has |
@msujew from debugging, I believe our behaviour is correct. Not sure why VS Code behaves differently, but one thing to keep in mind is that it is using a newer version of js-debug than what we are using. |
I debugged through this case in VS Code: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, thank you @tsmaeder for investigating this, I'll now gladly approve this PR :)
I can confirm that the changes work as expected and the property is marked as supported in the API comparison report.
What it does
Adds support for the
lifecycleSupportedByParent
flag on debug session. Fixes #11511How to test
Contributed on behalf of ST Microelectronics
Review checklist
Reminder for reviewers