-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
(Discussion) Possible to launch multiple debuggers? #4507
Comments
@factormystic you can run multiple debuggers easily by opening more VS Code windows. Every window supports one debugger. The only limitation is that you cannot run more than one debugger from a single project folder, because VS Code doesn't allow you to open a project folder in more than one window (we are planning to lift the limitation). |
I'm aware that it should be possible with multiple instances, by awkwardly opening different folders. That's kind of a hack and not particularly exciting, even though it is possible. The really exciting thing is the prospect of being able to run multiple debuggers at once in the same vs code instance, as I said. Much like it would not be very exciting if VS Code only allowed one type of syntax highlighting per instance, but instead loads separate syntax highlighting per file type. So again the question is, what kind of difficulties would be associated with launching a debugger not exclusively in a VS Code instance, but basically on a per file type (or other) basis? |
@factormystic VS Code supports one window and one extension host process per renderer: The VS Code debugger could easily manage multiple debug adapters, however they all would have to live in one window. Before going this route, we have would have to improve the UI support (multiple windows, etc.). Supporting multiple debugger instances in separate windows by using multiple renderer processes is trivial. We would just have to remove one line of code. This will come next. We are all using a single VS Code application with 4+ projects and 2 and 3 debuggers open. I don't view this setup as "awkward" as any other application with multiple windows. Running multiple debuggers behind one renderer process makes sense if the debuggers are actually operating in a coordinated way, but currently they are not. So the advantage of this approach is more of theoretical value for now. |
Interesting, thank you for explaining that @weinand. I agree that even more value would be had if separate debuggers were coordinated, but I disagree that such a thing is necessary to get value out of multiple debuggers. Again to my example, if I'm debugging a rails app & javascript, if I can place breakpoints in a controller and in the frontend right before an ajax request, it's not extremely necessary that control flow be automatically transferred from the js debugger to the ruby debugger or some magic like that... I can just wait for the ruby debugger's breakpoint to be hit. And, as you say, debugging the same project in multiple windows gets a lot of the way there and is already planned, which will be nice. |
I'm interested in understanding what it would take to be able to run multiple debuggers at once in the same vscode instance.
For example, simultaneously debugging a rails app's ruby code (eg, with the recently featured ruby debugger) and its javascript code (eg, with vs-chrome-debug). I'm envisioning breakpoints in both server and client code, with the respective debugger handling the respective file types.
How feasible is this? What kind of undertaking would it be to be able to activate more than one launch.json configuration entry at once?
The text was updated successfully, but these errors were encountered: