Chris,
My original reply jumped into the middle of the thread and I didn't completely
understand what you were asking. Let's get back to your original message:
On Sep 28, 2010, at 9:48 AM, Chris Withers wrote:
> The loop() function is supposed to be a "catch all and report" error handler.
> H
On Sep 30, 2010, at 1:51 AM, Zubin Mithra wrote:
> However, I am confused on how to write data over to a particular player(0 or
> 1). Is there any way I could choose to write to a particular object?
>
Sure, make self.factory.connections into a dictionary which maps player names
to connection
On 30/09/10 16:10, Chris Withers wrote:
> On 30/09/2010 15:53, Phil Mayers wrote:
>>> So, I appear to be back to the case where I can either gracefully handle
>>> the exception *or* gracefully handle the errback, but not both?
>>
>> It should be possible if using Twisted APIs correctly to reliably
Hello,
Garret Heaton wrote:
> I've simplified this issue down and am able to reproduce it without
> Twisted: http://gist.github.com/603154
>
> Still not sure what the cause is, so if anyone has any ideas I'd love to
> hear them. Thanks!
>
The behavior that you are seeing seems to be related to
On 30/09/2010 15:33, exar...@twistedmatrix.com wrote:
>> 2010-09-30 15:07:03,161 ERROR : log (22194|7f41910b26e0):
>> Unhandled Error
>> Traceback (most recent call last):
>>File "test_looping.py", line 47, in
>> reactor.run()
>>File "/twisted/internet/base.py", line 1166, in
On 30/09/2010 15:53, Phil Mayers wrote:
>> So, I appear to be back to the case where I can either gracefully handle
>> the exception *or* gracefully handle the errback, but not both?
>
> It should be possible if using Twisted APIs correctly to reliably
> capture errors.
>
> If it is not, that is a
On 30/09/10 15:35, Chris Withers wrote:
> On 30/09/2010 15:23, Phil Mayers wrote:
>>> def loop():
>>> d = maybeDeferred(doStuff)
>>> d.addErrback(partial(log.err,_why='Unhandled scheduled exception'))
>>
>>> So, how come my log.err doesn't get used for the AttributeError on
>>> connector?
>>
>> If
On 02:35 pm, ch...@simplistix.co.uk wrote:
>On 30/09/2010 15:23, Phil Mayers wrote:
>>>def loop():
>>>d = maybeDeferred(doStuff)
>>>d.addErrback(partial(log.err,_why='Unhandled scheduled exception'))
>>
>>>So, how come my log.err doesn't get used for the AttributeError on
>>>connector?
>>
>>If you
On 30/09/2010 15:23, Phil Mayers wrote:
>> def loop():
>> d = maybeDeferred(doStuff)
>> d.addErrback(partial(log.err,_why='Unhandled scheduled exception'))
>
>> So, how come my log.err doesn't get used for the AttributeError on
>> connector?
>
> If you mean in your most recent "test_looping.py" exa
On 02:13 pm, ch...@simplistix.co.uk wrote:
>On 30/09/2010 14:39, Jonathan Lange wrote:
>>On Thu, Sep 30, 2010 at 2:36 PM, Chris Withers
>>wrote:
>>...
>>>
>>>Is there any way I can get both errbacks *and* exceptions handled
>>>nicely in
>>>my `loop` call?
>>
>>You know about defer.maybeDeferred,
On 30/09/10 15:13, Chris Withers wrote:
> On 30/09/2010 14:39, Jonathan Lange wrote:
>> On Thu, Sep 30, 2010 at 2:36 PM, Chris Withers
>> wrote:
>> ...
>>>
>>> Is there any way I can get both errbacks *and* exceptions handled nicely in
>>> my `loop` call?
>>
>> You know about defer.maybeDeferred
On 30/09/2010 14:39, Jonathan Lange wrote:
> On Thu, Sep 30, 2010 at 2:36 PM, Chris Withers wrote:
> ...
>>
>> Is there any way I can get both errbacks *and* exceptions handled nicely in
>> my `loop` call?
>
> You know about defer.maybeDeferred, right?
Yep, the problem is with `loop` implemented
On 30/09/2010 14:46, Phil Mayers wrote:
> On 30/09/10 14:36, Chris Withers wrote:
>>
>> Indeed, but, as I keep saying, I need to build a scheduler that's
>> resilient to errors in the tasks its running ;-)
>
> Sure.
>
>>
Most prominent is reactor.callLater.
>>
>> ...which I'm not actually us
On 30/09/10 14:36, Chris Withers wrote:
>
> Indeed, but, as I keep saying, I need to build a scheduler that's
> resilient to errors in the tasks its running ;-)
Sure.
>
>>> Most prominent is reactor.callLater.
>
> ...which I'm not actually using, it was just a small-as-possible way I
> could simu
On Thu, Sep 30, 2010 at 2:36 PM, Chris Withers wrote:
...
>
> Is there any way I can get both errbacks *and* exceptions handled nicely in
> my `loop` call?
You know about defer.maybeDeferred, right?
jml
___
Twisted-Python mailing list
Twisted-Python@t
On 30/09/2010 14:03, Phil Mayers wrote:
On 30/09/10 13:44, Phil Mayers wrote:
This is because (as you've discovered) there are circumstances when a
function is called in Twisted where the exception can't propagate "up"
to the caller, because the caller is no longer higher in the call stack.
I
On 30/09/10 13:44, Phil Mayers wrote:
> This is because (as you've discovered) there are circumstances when a
> function is called in Twisted where the exception can't propagate "up"
> to the caller, because the caller is no longer higher in the call stack.
> Most prominent is reactor.callLater.
On 30/09/10 11:48, Chris Withers wrote:
> On 30/09/2010 04:45, exar...@twistedmatrix.com wrote:
>> On 12:52 am, ch...@simplistix.co.uk wrote:
>>>
>>> Because I haven't found any permutation that doesn't result in the
>>> LoopingCall's calls to `loop` from stopping after the exception.
>>>
>>> I wou
On 30/09/2010 04:45, exar...@twistedmatrix.com wrote:
> On 12:52 am, ch...@simplistix.co.uk wrote:
>>
>> Because I haven't found any permutation that doesn't result in the
>> LoopingCall's calls to `loop` from stopping after the exception.
>>
>> I would be more than ecstatic to be proved wrong ;-)
19 matches
Mail list logo