I am a new Python user and I have been programming in Matlab, so I decided to use Spyder IDE (which looks pretty much like Matlab IDE).
Right now I want to debug through (execute line by line in order to understand) some python code that is written as a class with several built-in functions. So, I inserted a breakpoint at the __init__
function of the class, however, when I started a debugging it did not go to the specified breakpoint (since I have to call for a class initialization, rather than just code execution).
Is it possible to start class debugging from the command line? In Matlab I would just call a function from the command line and it would stop at a specified breakpoint. Here I have to start a debugger, rahter than calling a function. If I simply call the following:
import energy_model
x = energy_model.EnergyModel()
It will just execute and ignore my breakpoint.
Hope my question is clear. Thanks, Mikhail