At 04:54 PM 8/14/2008, bob gailer wrote:
Dick Moores wrote:
At 08:58 PM 8/13/2008, bob gailer wrote:
One thing I really like about Python Win is the integrated debugger, which takes no time to start up. SPE OTOH uses WinPDB which runs as a separate process that takes (in the demo video) 15 seconds to start (each time it is requested)! Since I depend heavily on the debugger that delay would drive me crazy!

Hm, I just measured how long Ulipad takes to get going with WinPDB, a plug-in: 20 seconds, but 10 seconds for a restart.

Since you mention Ulipad I may have tried WinPDB there instead of SPE. I just remember trying it and not liking it. Python Win is totally integrated and seamless.

Other than the time to start, could you compare debugging with Python Win and debugging with WinPDB?

I'll taks a stab. All I know about WinPDB is what I see in the SPE video, so it probably is not the truth. What I see is a screen cluttered with a lot of windows, and having to switch application to access the output window or the code editor to make changes. Wth PyWin I work in the same familiar environment. The interactive window is available for viewing output and entering Python statements and expressions. If I want to see the stack or watch variables I can open floating or dockable windows.

Python Win serves my workflow. I am editing a script. I decide to run it so I can see what steps it takes and what values my variables are getting.

All I have to is press F10 in the active window and execution starts with the first statement. I can set breakpoints with F9, control execution with F11 F10 shift-F11 F5 and shift-F5. I can edit my source on the fly (changes of course do not take effect until the next execution cycle, and I must take care to not delete or add lines (the debugger does not know about such changes).

I can set a condition for a breakpoint.

OTOH WinPDB displays more information (witness locals globals exceptions and threads). I don't know how PythonWin handles threads.

Thanks very much for taking the time to write about something I've long wondered about.

As a Python learner, I found that getting acquainted with WinPDB made such a big difference in my ability to program, that I'm reluctant to change. I learned to use it through <https://gotgenes.com/swcatvtwiki/DebuggingExercise>

BTW you can set a condition for a breakpoint with it: See this example towards the bottom of the tutorial:

==================================
we need to set our conditional breakpoint. Look for the line number of the while loop statement:


while divisor <= 0:and set a conditional breakpoint for when divisor reaches the value 1.


bp 35, divisor == 1
====================================

Dick


_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to