Understand how to set breakpoints in Python code, inspect variables and data structures, and execute code line by line.
- [Tutor] Stepping through your program's entire code base … one line at a time can really quickly become tedious. … It's much easier to specify points in your code … where you want the debugger to stop when they're reached, … and this is what breakpoints are for. … So here in chapter three, lesson three, … let's go ahead and open up the code for geometry solver, … and I'm going to show you how to use breakpoints … to indicate the line of code … where you want execution to pause, … because the Python extension for Visual Studio Code … provides this ability for Python. … So to set a new breakpoint, … I can either click on a line of code, … and then in the Debug menu, I can choose … toggle breakpoint or new breakpoint. … Or I can click in the gutter between the files … and the line numbers, … these little red dots that are showing up. … If I click, then you'll see that a red dot shows up. … And if I switch the debug view, … you can see that down here in the breakpoint section … as I add breakpoints, they're listed here …
Released
5/13/2019- Constructing a simple Python program in VS Code
- Editing, formatting, and refactoring Python code
- Debugging Python code
- Setting breakpoints
- Using Python docstring
- Creating better comments for your source code
- Using the REST Client extension
Share this video
Embed this video
Video: Breakpoints