Questions tagged [vscode-debugger]

The Visual Studio Code debugger allows the developer to find errors in a program by pausing and inspecting the code.

The Visual Studio Code Debugger allows the developer to find errors in a program by pausing and inspecting the code.

References:

  1. Debugging User Guide
  2. Video tutorial
1999 questions
132
votes
13 answers

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 ?
BentOnCoding
  • 27,307
  • 14
  • 64
  • 92
94
votes
19 answers

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. -c qa or -c uat they are unbound: Why are the…
83
votes
14 answers

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 it possible to disable?
Revolt64
  • 941
  • 1
  • 6
  • 5
65
votes
12 answers

Debugger Not Stopping at Breakpoints in VS Code for Python

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 and runs the program like normal. I am using VS…
rogo8888
  • 651
  • 1
  • 5
  • 4
59
votes
5 answers

How to make vscode not wait for finishing a preLaunchTask?

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 have to run the binary before I can debug the JS…
Mike Lischke
  • 48,925
  • 16
  • 119
  • 181
51
votes
9 answers

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.json file under .vscode folder, I have a app.js…
Dev1ce
  • 5,390
  • 17
  • 90
  • 150
42
votes
7 answers

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": "attach", "port": 9222, "url":…
Stephane
  • 11,836
  • 25
  • 112
  • 175
38
votes
8 answers

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 fine the in the browser, from the terminal, with…
chuckd
  • 13,460
  • 29
  • 152
  • 331
36
votes
4 answers

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 the TSX code within the editor?
JLuis Estrada
  • 685
  • 1
  • 7
  • 15
34
votes
2 answers

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 here. I'd like to follow that advice, but I see…
Matt
  • 25,467
  • 18
  • 120
  • 187
28
votes
3 answers

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. The issue I'm having is that while debugging,…
TheGeekZn
  • 3,696
  • 10
  • 55
  • 91
27
votes
4 answers

Visual Studio Code LLDB on macOS error when starting debugging session

I'm trying to configure Visual Studio Code for compiling/debugging C++ programs on macOS. I am using the following launch.json file: When I try and start a debugging session, I get the following error: Warning: Debuggee TargetArchitecture not…
Jr795
  • 691
  • 1
  • 8
  • 15
24
votes
2 answers

Set breakpoint in imported python module in vs code

I am trying to set a breakpoint in an external Python module in VS code. I have tried editing the source file and inserting import pdb; pdb.set_trace() where I want the breakpoint. This enters the pdb command line debugger rather than the debugger…
RobinL
  • 11,009
  • 8
  • 48
  • 68
24
votes
5 answers

How to change string representation of objects in Nodejs debug console view

How do I change the string representation of an object instance in nodejs debug console. Is there a method (like toString() in .NET) I can override? Consider the following code: class SomeObject{ constructor(){ this._varA = "some…
Leo
  • 5,013
  • 1
  • 28
  • 65
23
votes
3 answers

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?
Amaan Zafar
  • 390
  • 1
  • 3
  • 9
1
2 3
99 100