debugging
Finding and fixing the cause of a bug, by observing what the program actually does and comparing it with what it should do.
In more detail
Good debugging starts from a hypothesis about the cause and tests it, instead of changing code at random. Tools range from adding temporary print calls to stepping through code in a debugger; a test that reproduces the bug keeps it from coming back.
Example
print(f"{total=}") prints both the name and value of total while debugging.Related terms
- breakpoint — A marked place in a program where execution pauses so you can inspect it in a debugger.
- playing computer — Following a program by hand, one statement at a time, writing down every variable's value in a table as it changes.
- bug — A mistake in a program that makes it fail or behave wrongly.
Taught in
- How The CTFL Exam Asks — ISTQB Certified Tester Foundation Level (CTFL v4.0) Exam Prep
- What Testing Is For, And What Debugging Is — ISTQB Certified Tester Foundation Level (CTFL v4.0) Exam Prep
- The Test Pyramid And The Testing Quadrants — ISTQB Certified Tester Foundation Level (CTFL v4.0) Exam Prep
- The Mock And Your Review Plan — ISTQB Certified Tester Foundation Level (CTFL v4.0) Exam Prep
- Editors, IDEs And Shells — Hands-on Python: Complete Video Course & Book
- A Graphics Introduction — Hands-on Python: Complete Video Course & Book
- Reading The graphics.py Documentation — Hands-on Python: Complete Video Course & Book
- Chapter Four In One Sitting — Hands-on Python: Complete Video Course & Book
- Debugging: print, breakpoint, and the debugger — Hands-on Python: Complete Video Course & Book