CCExtractor Development

Python: Write an automated Python debugger

One of the (many) cool things about Python is that it can debug itself! Yes, you can write a Python program that debugs a Python program.

You can read about this here:

https://www.freecodecamp.org/news/hacking-together-a-simple-graphical-python-debugger-efe7e6b1f9a8/

https://docs.python.org/3/library/inspect.html

https://python-hunter.readthedocs.io/en/latest/cookbook.html

Your job is to write a python program that runs a python function and for each line that is executed writes to the console what variables have changed and from what values to what values. For example

Line 13: 'x' changed from 2 to 3

You don't need to add breakpoints or anything fancy. For now, it's just about understanding the program flow.

Task tags

  • python
  • debugger

Students who completed this task

Lu Bolin, Lux, kashparty, Tantan4321, Musab Kılıç, Knob, LJ, AlephZero, Techno-Disaster, Krzysztof, moscwa, Vraj, SunnyGotSkillz, Diamondroxxx, kdrag0n, cppio, sohiltheacapulco, kevinjycui, Sudox, knightron0, dhrumilp15, azure

Task type

  • code Code
close

2019