Skip to content

Test Debug Sessions Picker #156193

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

Closed
3 tasks done
andreamah opened this issue Jul 25, 2022 · 1 comment
Closed
3 tasks done

Test Debug Sessions Picker #156193

andreamah opened this issue Jul 25, 2022 · 1 comment
Assignees
Milestone

Comments

@andreamah
Copy link
Contributor

andreamah commented Jul 25, 2022

Refs #153347

Complexity: 3

Create Issue


Set up:

Open up a folder that has files that you can run a debugger on (e.g. Python, JS). It would be amazing if people could try different debuggers!

Testing:

Start a debug session. If you can, please run multiple debug sessions at once and/or run sessions that spawn other sessions (running sessions that spawn child sessions will usually require you to write code within the program).

The command Debug: Select Debug Session should be present in the command palette when you search for it.

image

Select this option and this should show your debug sessions, including any children that are attached to debugging.

image

For each session in the list, the description (in slightly more faint text to the right of the name of the session) should be the parent session name if it has a parent. Also, depending on the debugger, there might be a section title that correspond to the group of sessions (in blue in the screenshot).

For example, the list of sessions that I showed above should correspond to this list of sessions the call stack view:

image

Clicking on any of the sesions should show the debug console in the context of that session.

You will be able to tell that the debug console is in the correct context if the call stack has highlighted the session that you selected.

Recording 2022-07-25 at 10 04 37

Extra tips:

Note that, in order to attach the debugger to children in Python, you need to specify "subProcess": true in the launch config for the debug session.

image

To run a subprocess in Python, I used the following code:

import subprocess as sp
sp.Popen([sys.executable, "test2.py"])

Where test2.py was another file in the same directory.

@isidorn
Copy link
Contributor

isidorn commented Jul 26, 2022

Nice work 👏

@github-actions github-actions bot locked and limited conversation to collaborators Sep 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants