Re: [Twisted-Python] deferred graph?

2012-07-22 Thread Eric Mangold
On Mon, 02 Jul 2012 19:31:14 -0500, Dan Stromberg wrote:On Thu, Jun 28, 2012 at 9:40 PM, Dan Stromberg wrote: Hi.I'm a Twisted neophyte, but I've been using Python a long time.My question: Is there a way of producing a deferred graph in a Python program at a given point in

Re: [Twisted-Python] deferred graph?

2012-07-18 Thread Tom Prince
Dan Stromberg writes: > Strangely, this doesn't give the report until after the sleep finishes... That is because the code you included doesn't actually print the returned traceback. The reason that it gets printed at the end is because it gets garbage collected then. The following code prints o

Re: [Twisted-Python] deferred graph?

2012-07-18 Thread Andrew Bennetts
Dan Stromberg wrote: > On Wed, Jul 18, 2012 at 3:32 AM, wrote: > > > > I don't think anything in the thread suggested that this approach will > > circumvent a time.sleep(10) call. > > I'm not sure where you're getting this circumvention issue from. At this point I'm not sure what the problem you

Re: [Twisted-Python] deferred graph?

2012-07-18 Thread Dan Stromberg
On Wed, Jul 18, 2012 at 3:32 AM, wrote: > > > I don't think anything in the thread suggested that this approach will > circumvent a time.sleep(10) call. I'm not sure where you're getting this circumvention issue from. > In any case, it won't. Why is there > a time.sleep(10) call there at all

Re: [Twisted-Python] deferred graph?

2012-07-18 Thread exarkun
On 02:24 am, drsali...@gmail.com wrote: >On Tue, Jul 17, 2012 at 12:53 PM, wrote: >>On 03:40 pm, drsali...@gmail.com wrote: >> >> >> >>Strangely, this doesn't give the report until after the sleep >> >>finishes... ? >> >>What's strange about that? "time.sleep(10)" doesn't mean "immediately >>pr

Re: [Twisted-Python] deferred graph?

2012-07-17 Thread Dan Stromberg
On Tue, Jul 17, 2012 at 12:53 PM, wrote: > On 03:40 pm, drsali...@gmail.com wrote: > >> > >>Strangely, this doesn't give the report until after the sleep > >>finishes... ? > > What's strange about that? "time.sleep(10)" doesn't mean "immediately > print out debug information". > Well, if you r

Re: [Twisted-Python] deferred graph?

2012-07-17 Thread exarkun
On 03:40 pm, drsali...@gmail.com wrote: >> >>Strangely, this doesn't give the report until after the sleep >>finishes... ? What's strange about that? "time.sleep(10)" doesn't mean "immediately print out debug information". It means "do not do anything at all in this program for around 10 sec

Re: [Twisted-Python] deferred graph?

2012-07-17 Thread Dan Stromberg
On Mon, Jul 16, 2012 at 11:45 PM, Dan Stromberg wrote: > > On Mon, Jul 16, 2012 at 11:20 PM, Andrew Bennetts > wrote: > >> Dan Stromberg wrote: >> […] >> > I'm playing with twisted.internet.defer.setDebugging now. >> > >> > Is there a corresponding function that can be used to produce its >> rep

Re: [Twisted-Python] deferred graph?

2012-07-16 Thread Dan Stromberg
On Mon, Jul 16, 2012 at 11:20 PM, Andrew Bennetts wrote: > Dan Stromberg wrote: > […] > > I'm playing with twisted.internet.defer.setDebugging now. > > > > Is there a corresponding function that can be used to produce its report? > > If I use it in a program with an infinite loop, it seems like I

Re: [Twisted-Python] deferred graph?

2012-07-16 Thread Andrew Bennetts
Dan Stromberg wrote: […] > I'm playing with twisted.internet.defer.setDebugging now. > > Is there a corresponding function that can be used to produce its report? > If I use it in a program with an infinite loop, it seems like I never get > the report, but if I use it in a program with a finite le

Re: [Twisted-Python] deferred graph?

2012-07-16 Thread Dan Stromberg
On Mon, Jul 16, 2012 at 9:54 PM, Andrew Bennetts wrote: > Dan Stromberg wrote: > […] > > Can anyone think of other ways of getting to the bottom of this? Perhaps > > some field in a deferred or deferredList I can introspect to get better > > specifics? > > > > Is monkey patching an identifier of

Re: [Twisted-Python] deferred graph?

2012-07-16 Thread Andrew Bennetts
Dan Stromberg wrote: […] > Can anyone think of other ways of getting to the bottom of this? Perhaps > some field in a deferred or deferredList I can introspect to get better > specifics? > > Is monkey patching an identifier of some sort into each deferred > reasonable? The intent would be to mak

Re: [Twisted-Python] deferred graph?

2012-07-16 Thread Dan Stromberg
I'm continuing to have some stuck deferreds - deferredlists probably. I had that graphviz/twisted graphing thing working for some test code, but upon applying it to some deferreds that're getting stuck in some production code, I didn't get the same pleasing output - not entirely surprising. Part o

Re: [Twisted-Python] deferred graph?

2012-07-10 Thread Eric P. Mangold
On Thu, Jun 28, 2012 at 08:42:20PM -0400, Terry Jones wrote: > Hi Glyph! > > There are a couple of tickets floating around: > > http://twistedmatrix.com/trac/ticket/3858 > http://twistedmatrix.com/trac/ticket/1402 (closed as a dupe) Please work on this!! I've had the idea in my head for a vi

Re: [Twisted-Python] deferred graph?

2012-07-02 Thread Dan Stromberg
On Thu, Jun 28, 2012 at 9:40 PM, Dan Stromberg wrote: > > Hi. > > I'm a Twisted neophyte, but I've been using Python a long time. > > My question: > Is there a way of producing a deferred graph in a Python program at a > given point in time? Perhaps something based on graphviz and objgraph.py? >

Re: [Twisted-Python] deferred graph?

2012-06-28 Thread Terry Jones
Hi Glyph! There are a couple of tickets floating around: http://twistedmatrix.com/trac/ticket/3858 http://twistedmatrix.com/trac/ticket/1402 (closed as a dupe) T ___ Twisted-Python mailing list Twisted-Python@twistedmatrix.com http://twistedmatrix

Re: [Twisted-Python] deferred graph?

2012-06-28 Thread Glyph
Le Jun 28, 2012 à 3:32 PM, Terry Jones a écrit : > You might be able to use this that I wrote some time ago. It might need > some maintenance as the Twisted Deferred code has moved on since then. But > the approach might help you: > > http://www.twistedmatrix.com/pipermail/twisted-python/2008-Oc

Re: [Twisted-Python] deferred graph?

2012-06-28 Thread Terry Jones
Hi Dan > I'm a Twisted neophyte, but I've been using Python a long time. I'm a Twisted neophyte, but I've been using Twisted a long time. (I'd add a smiley, but that's not a joke.) > My question: Is there a way of producing a deferred graph in a Python > program at a given point in time? Perha

Re: [Twisted-Python] deferred graph?

2012-06-28 Thread Laurens Van Houtven
You should still see the unhandled deferred in your logs if that's truly the case. On Thursday, June 28, 2012, Dan Stromberg wrote: > > Hi. > > I'm a Twisted neophyte, but I've been using Python a long time. > > My question: > Is there a way of producing a deferred graph in a Python program at a

[Twisted-Python] deferred graph?

2012-06-28 Thread Dan Stromberg
Hi. I'm a Twisted neophyte, but I've been using Python a long time. My question: Is there a way of producing a deferred graph in a Python program at a given point in time? Perhaps something based on graphviz and objgraph.py? We're able to detect when we're having the problem, we just don't (yet