Best Practices for Debugging
summary
A hands‑on course that walks through a broken Python pipeline parsing UniProt‑style FASTA files and shows concrete fixes: a missing colon causing a syntax error, a FileNotFound, a missing yield that drops the last record, stray newline/X characters that break an assertion, and a misplaced indentation. Demonstrates tools and tactics used: print debugging, pdb/ipdb with conditional breakpoints and assertions, linters, small unit inputs, bisection/Delta debugging, pandas and logging for larger pipelines. The example program is repaired step‑by‑step and ends with passing assertions and readable output.
AI-written summary · about
chapters (13)
- 0:00Python debugging intro
- 3:59Fixing Python syntax errors
- 6:05Handling Python runtime exceptions
- 10:47Debugging silent failures
- 12:36Print statements for debugging
- 15:50Scientific method in debugging
- 21:34Talking through problems
- 31:26Assertions for data consistency
- 33:45Interactive debugging with pdb
- 51:05Manual unit testing
- 1:01:46Advanced debugging techniques
- 1:11:34Logging for large programs
- 1:25:08Debugging is tiresome
related talks
23mDebugging that bugger : Cleanly handling the errors
12mDebugging Python in Production: Practical Techniques Beyond Print Statements
38mBuilding Data Pipelines in Python
34mHow to Debug Anything
23mEntomology 101: Effective Bug Hunting
18mDebugging Stories from an Advanced Python Class
41mAdvanced Python Debugging Techniques Using GDB
30mHow to Tune your Python Analysis Pipeline: A Profiler Guide
