2,227 questions
367
votes
14
answers
473k
views
How to set the working directory for debugging a Python program in VS Code?
How do I execute a Python file with the debugger and specify the working directory for the run?
312
votes
11
answers
329k
views
Visual Studio Code: How debug Python script with arguments
I'm using Visual Studio Code with the inbuilt Debugger in order to debug a Python script.
Following this guide, I set up the argument in the launch.json file:
But when I press on Debug, it says that ...
174
votes
15
answers
180k
views
How do you debug Jest Tests?
I can't find any information on debugging my unit tests written with Jest.
How do you debug Jest Tests ?
115
votes
16
answers
179k
views
How to disable "just my code" setting in VSCode debugger?
When starting my project in the debugger (C# .NET Core), it states it's debugging "just my code".
I want to also debug the libraries, and can't see a setting to disable this anywhere in VSCode.
Is ...
109
votes
22
answers
175k
views
Unbound breakpoint - VS Code | Chrome | Angular
I have an Angular application that I am trying to debug in VS Code.
When I compile and run the application (ng serve) the breakpoints are bound:
However, when I specify a different configuration e.g. ...
104
votes
15
answers
117k
views
VSCode: Why isn't debugger stopping at breakpoints?
I have just installed VS Code and the Python extension, and I have not been able to get the debugger to work. Every time I try to use the debugger, it just skips over any breakpoints that I have set ...
81
votes
5
answers
38k
views
How can I prevent VS Code from waiting for a preLaunchTask to finish?
I have a debug setup in Visual Studio code where I run an external binary which can execute my JS files (using duktape). The debug adapter currently only supports attach requests (not launch) so I ...
69
votes
9
answers
90k
views
Is there a way to debug code in VsCode initiated with Vite?
My dev team configured a Node.js project with TypeScript to use Vite as dev server, using the npm script panel of VsCode.
Is there a way to attach the debugger into this Vite server so we can debug ...
58
votes
10
answers
74k
views
How to debug a nodemon project in VSCode
I have a NodeJs project and I run it using nodemon,
I wish to run it in debug mode for development tasks, but I am unable to do so.
I found that I'll need to add the right configuration to the launch....
50
votes
8
answers
32k
views
How to attach the VSCode debugger to the Brave browser?
When I open my web application in the Chrome browser I can attach the VSCode debugger to it.
The debugger configuration is:
{
"name": "Attach to Chrome",
"type": "chrome",
"request": "...
42
votes
10
answers
55k
views
My Angular application doesn't hit breakpoint when debugging?
Kinda new to Visual Studio Code and Angular applications with a C# Web API back-end. No problem hitting a breakpoint in C#, just not hitting it in Angular app in VS Code!
I can run both apps just ...
41
votes
2
answers
33k
views
How to display current values of VS Code's predefined variables (such as "${workspaceFolder}" or "${fileWorkspaceFolder}")?
I am facing an issue with VS code debugger while trying to debug some angular typescript source code, and I think the reason is that some of those VS Code Variables have the wrong value - as suggested ...
40
votes
6
answers
75k
views
"You don't have an extension for debugging 'JSON with Comments'" warning when debugging VS Code theme
I generated the files necessary for creating a color theme in VS Code. I did this with the generator-code node package.
My file structure is as follows
When I run VS Code's debugger, I get this ...
39
votes
4
answers
121k
views
Where is the 'launch.json' file in Visual Studio Code?
The launch.json file should be inside the .vscode folder, but it is not present there.
How can I get this file so that I can modify the configurations?
34
votes
3
answers
16k
views
Dart / Flutter - Debugger stops on caught exceptions
In a relatively simple block of code that checks an API endpoint (determining connection state), I rely on a try..catch as the mechanism to validate if the application can communicate with the server.
...