[Twisted-Python] How do I run a twisted server directly

Alexander May alex-news at comcast.net
Sat May 15 00:25:17 EDT 2004


> Why are you assuming that you can't use twistd and komodo's debugger at
the same time? 

I'm new to both twisted and Komodo, and never even considered that such on
option existed.  Thanks for the info, I'll see if I can manage it.  Is there
a similar mechanism for other IDEs?

Alex



-----Original Message-----
From: twisted-python-bounces at twistedmatrix.com
[mailto:twisted-python-bounces at twistedmatrix.com] On Behalf Of Donovan
Preston
Sent: Saturday, May 15, 2004 12:00 AM
To: Twisted discussion stuff
Subject: Re: [Twisted-Python] How do I run a twisted server directly


On May 14, 2004, at 10:02 PM, Alexander May wrote:

> I've use pythonwin for a while and I'm giving Komodo try right now.  
> I'll
> try Python.NET soon too.

<snip>

>
> Which seems to work.  I can start my application from the debugger and 
> hit breakpoints, etc.
>
> Presumably I've committed all sort of horrors writing this code.  
> Please
> feel free to enlighten me to the error of my ways.  Also, I'm curious 
> what is the function of the following line of code (marked with a *) 
> is which I saw in twistw:

<snip>

Why are you assuming that you can't use twistd and komodo's debugger at the
same time? The last time I looked at Komodo for debugging (which admittedly
was at least two years ago) importing the debugging module at any time
installed the trace hook and queried Komodo for breakpoints. Then, any time
the trace hook wanted to break into the debugger, it made a synchronous,
blocking call over xmlrpc into the Komodo process. The Komodo process would
then delay 'returning' from that xmlrpc call until you pressed step or
continue in the ui.

You should just be able to import the komodo debugging shim module at the
top of your .tac file, start it using twistd, and debug just fine.

dp


_______________________________________________
Twisted-Python mailing list
Twisted-Python at twistedmatrix.com
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python





More information about the Twisted-Python mailing list