[Twisted-Python] How to use the TimeoutProtocol policy?

2018-06-14 Thread Martin van Es
to login\nand press to continue." % line)) self.state = None else: self.transport.loseConnection() Before anyone starts to scream http (no s): This is all test/debug. I want the timeout to work before I deploy to something more serious. The client is loaded straightforward using a reactor.connectTCP() with th

Re: [Twisted-Python] Catching error in protocol.ReconnectingClientFactory

2012-06-28 Thread Martin
On 28/06/12 12:46, Martin wrote: On 26/06/12 15:12, exar...@twistedmatrix.com wrote: On 25 Jun, 12:16 pm, mar...@webscio.net wrote: No suggestions as to how I could get rid of this? :( I put together a minimal example of ReconnectingClientFactory for the connection refused case for you

Re: [Twisted-Python] Catching error in protocol.ReconnectingClientFactory

2012-06-28 Thread Martin
On 26/06/12 15:12, exar...@twistedmatrix.com wrote: On 25 Jun, 12:16 pm, mar...@webscio.net wrote: No suggestions as to how I could get rid of this? :( I put together a minimal example of ReconnectingClientFactory for the connection refused case for you. It's attached. I don't see any er

Re: [Twisted-Python] Catching error in protocol.ReconnectingClientFactory

2012-06-25 Thread Martin
On 25/06/12 22:27, Adrian Overbury wrote: > On 25/06/2012, at 10:16 PM, Martin wrote: > >> On 14/06/12 12:38, Martin wrote: >>> Hi, thanks for your reply. >>> >>> Indeed, the ReconnectingClientFactory is being sent the Failure object to >>> >

Re: [Twisted-Python] Catching error in protocol.ReconnectingClientFactory

2012-06-25 Thread Martin
On 14/06/12 12:38, Martin wrote: > Hi, thanks for your reply. > > Indeed, the ReconnectingClientFactory is being sent the Failure object to > > def clientConnectionLost(self, connector, reason): > log.msg('Lost connectio

Re: [Twisted-Python] iConnector factory not what expected

2012-06-25 Thread Martin
On 15/06/12 14:15, exar...@twistedmatrix.com wrote: > On 08:50 am, mar...@webscio.net wrote: >> On 15/06/12 01:40, exar...@twistedmatrix.com wrote: >>> On 14 Jun, 03:34 pm, mar...@webscio.net wrote: Hi again, I've a bit of code that does the following: f = MyReconnectingCli

Re: [Twisted-Python] iConnector factory not what expected

2012-06-15 Thread Martin
On 15/06/12 14:15, exar...@twistedmatrix.com wrote: > On 08:50 am, mar...@webscio.net wrote: >> On 15/06/12 01:40, exar...@twistedmatrix.com wrote: >>> On 14 Jun, 03:34 pm, mar...@webscio.net wrote: Hi again, I've a bit of code that does the following: f = MyReconnectingCli

Re: [Twisted-Python] iConnector factory not what expected

2012-06-15 Thread Martin
On 15/06/12 01:40, exar...@twistedmatrix.com wrote: > On 14 Jun, 03:34 pm, mar...@webscio.net wrote: >> Hi again, >> >> I've a bit of code that does the following: >> >> f = MyReconnectingClientFactory() >> iConn = reactor.connectSSL(url, port, f, ssl.ClientContextFactory()) >> >> now I would expec

[Twisted-Python] iConnector factory not what expected

2012-06-14 Thread Martin
Hi again, I've a bit of code that does the following: f = MyReconnectingClientFactory() iConn = reactor.connectSSL(url, port, f, ssl.ClientContextFactory()) now I would expect that iConn.factory would be my f, but as it turns out it's an instance of some TLSMemoryBIOFactory.. Why is that so? A

Re: [Twisted-Python] Catching error in protocol.ReconnectingClientFactory

2012-06-14 Thread Martin
Any thoughts? Thanks a lot! > On Jun 11, 2012, at 8:01 AM, Martin wrote: > >> Hi there, >> >> I've been looking around for a solution for several hours now, and maybe >> I'm just missing something.. >> >> I've a factory that implements protocol.

[Twisted-Python] Catching error in protocol.ReconnectingClientFactory

2012-06-11 Thread Martin
need to print it out at the end. Anyway, I don't claim to be anywhere near proficient in Twisted, so any help would be greatly appreciated. Thanks a lot in advance. Martin ___ Twisted-Python mailing list Twisted-Python@twistedmatrix.com ht

Re: [Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

2010-08-28 Thread Martin Nordholts
ers {0: 8, 1: 9, 2: 11} ::connectionMade starting _setupChild fdmap {0: 7, 1: 10, 2: 14} os.dup2(7,0) os.dup2(10,1) os.dup2(14,2) ::errReceived old [7, 10, 14] ::outReceived Cloning into gimp... A -q argument did, as expected, not help. / Martin ___

Re: [Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

2010-08-28 Thread Martin Nordholts
til it has things to put there. I have git version 1.7.2.2 / Martin ___ Twisted-Python mailing list Twisted-Python@twistedmatrix.com http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Re: [Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

2010-08-28 Thread Martin Nordholts
On 08/28/2010 05:02 PM, Petr Mifek wrote: > Hi Martin, > > I tried your code just for the curiosity and it seems to work here. Are > you sure it doesn't work? Hi, Thanks for testing the code. Interesting that it works for you. I hope we can understand why when we've fo

Re: [Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

2010-08-28 Thread Martin Nordholts
On 08/28/2010 03:32 PM, Itamar Turner-Trauring wrote: > On Sat, 2010-08-28 at 11:31 +0200, Martin Nordholts wrote: > >> I'll see if I can pinpoint the bug... > > If you can reproduce this with a Python program you launch, rather than > git, that would be ideal. > >

Re: [Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

2010-08-28 Thread Martin Nordholts
On 08/28/2010 09:34 AM, Martin Nordholts wrote: > Hi > > I am getting a weird problem where git cloning with > reactor.spawnProcess() fails for some repositories. It appears as if > Twisted blocks reading from the server socket that git packs should come > on. Started to de

Re: [Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

2010-08-28 Thread Martin Nordholts
On 08/28/2010 09:34 AM, Martin Nordholts wrote: > I see this problem on Fedora 13 x86_64, both with the distro version > Twisted 0.8.2 Sorry, that should have been 8.2.0. / Martin ___ Twisted-Python mailing list Twisted-Python@twistedmatrix.co

[Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

2010-08-28 Thread Martin Nordholts
st stable release Twisted 10.1.0. My personal guess is that it has something to do with how spawnProcess() manages the fds or the child process. Does anyone have any guess of what is going on? Can you reproduce it on other systems? Thanks in advance for any input. Regards, Martin

Re: [Twisted-Python] deciding to use twisted or not

2009-09-06 Thread Martin-Louis Bright
Brilliant! Thank you. -martin On Sun, Sep 6, 2009 at 10:46 AM, Alexandre Quessy wrote: > Hi ! > You might want to look at my implementation of a tail -F : > https://svn.sat.qc.ca/trac/miville/browser/trunk/py/miville/utils/tail.py > Let me know if you have better than that. > a &

[Twisted-Python] twistd plugin or .tac file?

2009-09-01 Thread Martin-Louis Bright
achieve this if your app doesn't need a network port? -martin ___ Twisted-Python mailing list Twisted-Python@twistedmatrix.com http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Re: [Twisted-Python] deciding to use twisted or not

2009-09-01 Thread Martin-Louis Bright
PyInotify only allows you to detect file changes, leaving you with the task of asynchronously sending http requests. -martin On Thu, Aug 27, 2009 at 12:19 PM, Mikhail wrote: > Martin-Louis Bright gmail.com> writes: > > > > > > > I am using linux, and I want the da

Re: [Twisted-Python] deciding to use twisted or not

2009-08-27 Thread Martin-Louis Bright
#x27;t work, Glyph's LoopingCall with a read() approach. Thanks for the link. -martin On Thu, Aug 27, 2009 at 8:11 AM, Chris Adams wrote: > If you're using a linux based system, you may have some luck setting > up syslogger to forward logging packets to the remote ip address, and >

Re: [Twisted-Python] deciding to use twisted or not

2009-08-26 Thread Martin-Louis Bright
Thanks! Your advice is much appreciated. martin On Wed, Aug 26, 2009 at 10:08 PM, Glyph Lefkowitz wrote: > On Wed, Aug 26, 2009 at 9:54 PM, Cary Hull wrote: > >> It would certainly be nice if Twisted supported async file io, but in this >> case wouldn't a ProcessProtoco

[Twisted-Python] deciding to use twisted or not

2009-08-26 Thread Martin-Louis Bright
overkill... Martin ___ Twisted-Python mailing list Twisted-Python@twistedmatrix.com http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

[Twisted-Python] Re: Reentrant reactor iteration

2009-03-07 Thread Martin Geisler
Jean-Paul Calderone writes: > On Sat, 07 Mar 2009 19:38:46 +0100, Martin Geisler wrote: > >> We have overloaded the arithmetic operators in our library, so people >> will expect to be able to write >> >> # xs and ys are big lists of our objects >> dot_

[Twisted-Python] Re: Reentrant reactor iteration

2009-03-07 Thread Martin Geisler
tail call optimization in Python, each level in the recursion will hold onto any local variables even though they might not be needed any more. Are there other general problems with having a re-entrant reactor? -- Martin Geisler VIFF (Virtual Ideal Functionality Framework) brings e

[Twisted-Python] Re: How to write (network) integration tests with Twisted?

2009-01-26 Thread Martin Geisler
normal application, but the communication is done with function calls instead of actual network traffic. -- Martin Geisler VIFF (Virtual Ideal Functionality Framework) brings easy and efficient SMPC (Secure Multiparty Computation) to Python. See: http://viff.dk/. pgp9RWQrRlo8N.pgp Description: P

[Twisted-Python] Re: Mailing list archive search?

2009-01-19 Thread Martin Geisler
here: http://dir.gmane.org/gmane.comp.python.twisted -- Martin Geisler VIFF (Virtual Ideal Functionality Framework) brings easy and efficient SMPC (Secure Multiparty Computation) to Python. See: http://viff.dk/. pgpsiA58JAa06.pgp Description: