[PyKDE] pyQt and PythonWin

Phil Thompson phil at river-bank.demon.co.uk
Fri Sep 21 01:59:09 BST 2001


Boudewijn Rempt wrote:
> 
> On Wednesday 19 September 2001 21:47, you wrote:
> > Hello!
> > I am experiencing some troubles trying to run pyQt from PythonWin
> > environment. When the tutorial sctipts provided with the pyQt are run from
> > the DOS path like "python tut1.py" all goes fine, but PythonWin is quite
> > different: PythonWin itself halts after the "a.exec_loop()" instruction is
> > executed, as for the screen, an empty Qt window frame appears after a
> > while, halted as well. Is this a known problem that PythonWin dislikes pyQt
> > scripts? if yes, is it mendable or not? I am just looking for a way to
> > debug pyQt scripts on Win32.
> 
> It's quite possible that Pythonwin has problems - it can't
> debug tkinter scripts either. Your best bet would be to
> try BlackAdder. The BlackAdder debugger can do most of the
> things I remember Pythonwin could, but fits PyQt like a glove.

Debuggers usually have problems debugging scripts that have their own
event loops (as any GUI application does) if they don't have explicit
support for it. BlackAdder goes to some trouble to co-operate with the
Qt event loop in the script being debugged (that's what the PreHook and
PostHook options are for - see qapplication.sip).

One thing that I really liked about Tk was the ability to execute Tcl
statements at the wish prompt while your script was running. BlackAdder
allows you to do the same thing.

Phil




More information about the PyQt mailing list