Skip Montanaro <skip.montan...@gmail.com> wrote: > CW> How do you troubleshooting/debugging in Python? > > GE> Mostly I read exception trace and read the code and think about it. > GE> If that doesn't work, I add some print() or syslog() calls. > > CW> I know hardcore computer scientists would tell me about Python debugger. > > GE> I've been writing Python for 20+ years. I've never tried a debugger. > > Agree with Grant on these points. I certainly use gdb to debug C code > (like the interpreter), but for Python code, tracebacks and print > statements pretty much take care of things. I know pdb has been around > for a long while and many people like IDEs, but I've not generally > found them all that useful. I'm stuck in the 90s I guess. > Me too! :-)
I tend to use multiple terminal windows so I have the code being edited in one window, run the code in another window and sometimes a third window for looking at configuration etc. Add print statement etc. for debugging. -- Chris Green ยท -- https://mail.python.org/mailman/listinfo/python-list