Debugging the Python code during PSSe dynamic simulation
Dear all,
I need to debug the Python code during the runtime of Psse dynamic simulation to check the values in the variables that I have used and also to see the flow of the program that I have written. Could anyone please help with a way to do this?
Thank you in advance
''pdb.set_trace()'' may work. It may not work depending how your output is being redirected.
Thank you for your answers. Yes, I figured out that pdb.set_trace() works well if you want to do line by line debug. Also, print command helps a lot. But Does anyone know of a way to send the control to for example the next breakpoint as we do in Matlab? Please suggest.
pdb is a full debugger, you can set breakpoints. If you want a pretty IDE give PyCharm or Spyder a try. If you go the Spyder route, I recommend you get it via PythonXY.