Re: [Twisted-Python] Twisted Plugins - Implementation Discussion

2011-04-06 Thread Phil Christensen
On Apr 6, 2011, at 8:35 PM, Stephen Thorne wrote: > For your consideration, and (constructive) critcism, here is a twisted > plugin that is nearly identical to 6 that I have running in > production: [snip] > serviceMaker = ExampleServiceMaker() > > From these 19 lines of code there are 4 things t

Re: [Twisted-Python] What's the purpose of __?

2011-02-15 Thread Phil Christensen
On Feb 15, 2011, at 5:36 AM, Attila Nagy wrote: > Hi, > > I'm trying to do an LMTP implementation based on smtp.py and came to the > issue of class private variables with double underscores. > Examples: > http://twistedmatrix.com/trac/browser/trunk/twisted/mail/smtp.py#L746 > http://twistedmatrix

Re: [Twisted-Python] Porting twisted methods to a synchronous environment

2011-01-24 Thread Phil Christensen
On Jan 24, 2011, at 2:26 PM, Don Dwiggins wrote: > I have a server that provides access to a database in the usual way, > using adbapi to talk to an MSSQL server. Now, I'm facing the need to > create an application that can access the server directly. (In addition > to, not instead of.) Why d

[Twisted-Python] ANN: antioch 1.0 developer preview released

2010-12-17 Thread Phil Christensen
Hey all, So, I've recently made big strides with an old project that I've been kicking around ever since working on Divunal back in the Twisted Reality days. Since it uses several Twisted-community projects to solve some problems I've been tinkering with for years, the first place I hoped to re

Re: [Twisted-Python] Escaping variable names

2010-03-05 Thread Phil Christensen
On Mar 5, 2010, at 12:15 PM, Kamil Wasilewski wrote: > server.soapproxy.config.argsOrdering = {'doGetCountries': ['country-code', > 'webapi-key'] } > server.doGetCountries(country-code=COUNTRYID}, webapi-key=WEBAPIKEY) > > The above method allows me to specify the order and name of variables bein

Re: [Twisted-Python] fast high load protocol

2010-02-16 Thread Phil Christensen
On Feb 16, 2010, at 2:46 PM, Vlad Shevchenko wrote: > I have developed two kind of servers: >api - http server >memory_db - dict-based server with some logic of putting data to dict and > getting it back. > > Api communicate with memory_db via txJSON-RPC but response time is huge under >

Re: [Twisted-Python] WSGI Question

2010-01-20 Thread Phil Christensen
On Jan 20, 2010, at 3:23 PM, Alex Clemesha wrote: > I really want to getting reloading going. I already have a ticket here: > http://github.com/clemesha/hotdot/issues#issue/2 > that describes this issue, with a couple of notes. Please add to this > ticket / post any patches if you getting anywher

Re: [Twisted-Python] WSGI Production ready

2010-01-20 Thread Phil Christensen
On Jan 20, 2010, at 1:19 PM, adamjamesdrew same wrote: > Is twisted WSGI production ready as compared to apache and mod_wsgi > > For a simple server with 4 cores would you simple start 4 instances and load > balance between them? > How would you recommend a production deploy of twisted wsgi? Twi

Re: [Twisted-Python] WSGI Question

2010-01-20 Thread Phil Christensen
On Jan 20, 2010, at 10:40 AM, Landreville wrote: > On Wed, Jan 20, 2010 at 9:58 AM, adamjamesdrew same > wrote: >> I deploy code. Then I modify the code on my file system. The code does not >> automatically change on the server. It does this on the django dev server. >> How can I make this happen

Re: [Twisted-Python] WSGI Question

2010-01-20 Thread Phil Christensen
On Jan 20, 2010, at 9:58 AM, adamjamesdrew same wrote: > I deploy code. Then I modify the code on my file system. The code does not > automatically change on the server. It does this on the django dev server. > How can I make this happen? This is a Django-specific feature that doesn't exist in T

Re: [Twisted-Python] twisted version of openid

2009-12-29 Thread Phil Christensen
On Dec 29, 2009, at 1:31 PM, Kevin Horn wrote: On Tue, Dec 29, 2009 at 10:12 AM, Raj kumar wrote: Hi, Currently I'm having a server running under twisted. I'm planning to implement openid in my application. Is there any twisted version of openid api? I need some reference to go through ope

Re: [Twisted-Python] Downpour - new project using Twisted

2009-12-15 Thread Phil Christensen
This is really cool, I can't wait to check it out. I also wanted to suggest that you add your project to the 'tx' super-group on Launchpad. It will group it with a lot of other Twisted community projects, and has some other nice features. You can even have it automagically sync the launchpad re

Re: [Twisted-Python] web vs web2 clarification

2009-12-10 Thread Phil Christensen
On Dec 10, 2009, at 2:21 PM, Mikhail Terekhov wrote: > Just some unrelated rant about Joel&Co : > > Joel talks about big _commercial_ projects and _commercial_ failures. > May be he is right here, may be not. But it is this rewrite from scratch that > gave birth to Mozilla - number one web/email s

Re: [Twisted-Python] exarkun changed [#4029 - Twisted Web's wsgi.input isn't sufficiently file-like in all cases]

2009-11-16 Thread Phil Christensen
Uh, sorry about that. You know, working this crazy email nonsense is hard for old codgers like me. -phil On Nov 16, 2009, at 9:56 PM, Phil Christensen wrote: > > > -phil > > [sent from my phone] > > O ___ Twisted-Python mailin

Re: [Twisted-Python] exarkun changed [#4029 - Twisted Web's wsgi.input isn't sufficiently file-like in all cases]

2009-11-16 Thread Phil Christensen
-phil [sent from my phone] On Nov 16, 2009, at 4:56 PM, t...@twistedmatrix.com wrote: > Ticket [#4029 - Twisted Web's wsgi.input isn't sufficiently file- > like in all cases] changed by exarkun : > > (In [27518]) Merge wsgi-none-readline-4029 > > Author: rikyu > Reviewer: exarkun > Fixes: #40

Re: [Twisted-Python] sleeping in inlineCallbacks

2009-10-07 Thread Phil Christensen
On Oct 7, 2009, at 3:46 PM, Matt Perry wrote: > On 7 Oct 2009, at 20:30, Paul Thomas wrote: >> Is there any way to do something like "yield sleep(10)" inside an >> @inlineCallbacks method? >> >> I realise I can do this: >> >> def sleep(seconds): >> d = defer.Deferred() >> reactor.callLater

Re: [Twisted-Python] Is it necessary to utilize twisted.cred in twisted web?

2009-10-05 Thread Phil Christensen
crossposted to twisted-...@twistedmatrix.com, which is probably a better venue... On Oct 6, 2009, at 12:08 AM, biziap biziap wrote: > I have googled this topic and found and example in > (A) http://www.mail-archive.com/twisted-...@twistedmatrix.com/msg01796.html > well, another simpler example i

Re: [Twisted-Python] strange exception on Python 2.6 + Snow Leopard

2009-09-29 Thread Phil Christensen
On Sep 29, 2009, at 4:42 PM, exar...@twistedmatrix.com wrote: > On 08:37 pm, p...@bubblehouse.org wrote: >> I do see the following issues during compilation, which cause the >> epoll reactor to fail. I don't use the epoll reactor, so I haven't >> bothered trying to fix it: [snip] > These aren't rea

Re: [Twisted-Python] strange exception on Python 2.6 + Snow Leopard

2009-09-29 Thread Phil Christensen
On Sep 29, 2009, at 3:08 PM, Steve Steiner (listsin) wrote: >> Hmm, sorry to question, but are you sure? > > You're right, different error. Sorry for not replying earlier -- just > found this when Googling for 10.6 build instructions as I'm having a > devil of a time building from SVN on 10.6 with

Re: [Twisted-Python] os x installer, multiple source locations

2009-09-07 Thread Phil Christensen
irst time I've heard it come up on the list since I ran into it, which may be why it hasn't been added to the install docs. I'm sure a docs patch would be well received, if you were so inclined ;-) On Sep 6, 2009, at 4:14 PM, Matt Bennett wrote: > On Sun, Sep 6, 2009 at

Re: [Twisted-Python] os x installer, multiple source locations

2009-09-05 Thread Phil Christensen
On Sep 4, 2009, at 7:50 PM, Matt Bennett wrote: > Hello all, > > I used the Twisted 8.2.0 for OS X 10.5 installer from [1] to install > twisted on my mac. I don't understand why, but I seem to have two > copies of the source on the disk This is a frustrating partial install of Twisted that ships w

Re: [Twisted-Python] strange exception on Python 2.6 + Snow Leopard

2009-08-31 Thread Phil Christensen
On Aug 31, 2009, at 3:47 PM, Steve Steiner (listsin) wrote: > On Aug 31, 2009, at 3:36 PM, Phil Christensen wrote: >> hey all, >> >> I just upgraded to Mac OS X 10.6 which includes Python 2.6.1. I'm >> running the latest SVN HEAD of Twisted, but when I run twistd I

[Twisted-Python] strange exception on Python 2.6 + Snow Leopard

2009-08-31 Thread Phil Christensen
hey all, I just upgraded to Mac OS X 10.6 which includes Python 2.6.1. I'm running the latest SVN HEAD of Twisted, but when I run twistd I get an exception before it continues working (apparently) normally. Here's what I'm seeing: thrawn:~ phil$ twistd Traceback (most recent call last):

Re: [Twisted-Python] Some way for Trial to allow selective running of tests?

2009-08-27 Thread Phil Christensen
On Aug 27, 2009, at 4:00 PM, Don Dwiggins wrote: > I've been successfully and happily using Trial for a while now for > development of a server. I have many tests at this point; during > development of a new feature, I'd like to have a convenient way to > only > run the tests relevant to that fe

Re: [Twisted-Python] A C/S Application over Internet

2009-08-27 Thread Phil Christensen
On Aug 27, 2009, at 10:57 AM, 陶艺夫 wrote: > Thank you, Phil. > > Pyro has many examples, so I can understand it easily. I know > Twisted is great. I think your "switching" must mean something :) . > So I decide to use twisted PB. Great! I also remembered one thing that I found was extremely use

Re: [Twisted-Python] A C/S Application over Internet

2009-08-27 Thread Phil Christensen
On Aug 27, 2009, at 9:33 AM, 陶艺夫 wrote: > I want to develop an C/S app over internet using twisted Perspective > Broker. The server will run as a windows service, and the clients > will be wxPython desktop applications. > Has anyone done the same thing or known the trick to do it? Shoud > I

Re: [Twisted-Python] OT - adbapi, connection timeouts, mysql - OT

2009-08-25 Thread Phil Christensen
On Aug 25, 2009, at 11:25 AM, Phil Mayers wrote: > Phil Christensen wrote: >> Honestly, I have never actually solved it. I pretty much only write >> webapps these days, so when a ConnectionLost happens, it just >> propagates up the stack and displays an error to the user.

Re: [Twisted-Python] OT - adbapi, connection timeouts, mysql - OT

2009-08-25 Thread Phil Christensen
On Aug 24, 2009, at 9:14 PM, Garret Heaton wrote: > On Mon, Aug 24, 2009 at 3:53 PM, Phil Christensen > wrote: >> I feel like I can think of any number of ways running the same >> series of queries twice would be a bad thing. I have some very >> important queri

Re: [Twisted-Python] OT - adbapi, connection timeouts, mysql - OT

2009-08-24 Thread Phil Christensen
On Aug 24, 2009, at 2:58 PM, Garret Heaton wrote: There is a solution to the reconnection issue posted here which one of my friends improved upon. He wasn't on the list at the time of this posting so I'm replying to this on his behalf. The improved solution is: [snip] # try the

[Twisted-Python] weird spammy trac emails?

2009-08-19 Thread Phil Christensen
Hey all, Have any of you gotten these weird spammy messages from trac? I'm getting change notifications on tickets I opened years ago, with no apparent info in it about what the change is except a spam URL. I've attached the ones I've received. I can't figure out how this would even be poss

Re: [Twisted-Python] Questions about adding documentation

2009-07-31 Thread Phil Christensen
On Jul 31, 2009, at 2:15 PM, Kevin Horn wrote: > Well, pragmatism is my basic reason for not liking wikis for docs. :) > > For me, it boils down to every time I've worked on or with a project > that used wikis for docs (assuming that the project is of at least > moderate size and has more than

Re: [Twisted-Python] Questions about adding documentation

2009-07-31 Thread Phil Christensen
On Jul 31, 2009, at 1:34 PM, Kevin Horn wrote: > >Also, what do the Twisted core devs think about having a secondary > >wiki/cookbook thingy outside of the core docs? > > As a staging area for development of future core docs, I think I would > recommend using a version control system (perhaps a di

Re: [Twisted-Python] Questions about adding documentation

2009-07-31 Thread Phil Christensen
On Jul 31, 2009, at 1:11 PM, Jean-Paul Calderone wrote: > As a staging area for development of future core docs, I think I would > recommend using a version control system (perhaps a distributed one), > not a wiki. What I was suggesting originally was that a wiki would be a staging ground for th

Re: [Twisted-Python] Questions about adding documentation

2009-07-31 Thread Phil Christensen
On Jul 31, 2009, at 12:32 PM, Reza Lotun wrote: >> Even if I re-suggested the wiki based documentation, I think it's >> important to be extra careful on how it's used. One thing I >> personally >> hate is projects whose documentation is basically wiki-based, and >> what >> you end having is a d

Re: [Twisted-Python] Questions about adding documentation

2009-07-31 Thread Phil Christensen
On Jul 31, 2009, at 10:19 AM, Santiago Aguiar wrote: > It could also be a good idea to try to make it more wiki-like at the > beginning; I think there's quite a lot of people that would like to > contribute with this, but having different documents/styles for > different areas of the doc is not goo

Re: [Twisted-Python] untwisting twistd

2009-07-02 Thread Phil Christensen
On Jul 2, 2009, at 12:08 AM, Mikhail wrote: > IMHO there is a misunderstanding here. The point, at least from my > POV is > to have the same functionality provided by twistd but with a different > interface. Right now twistd is a starter script that is used like: > >twistd -noy -l my.log my_a

Re: [Twisted-Python] untwisting twistd

2009-06-24 Thread Phil Christensen
On Jun 23, 2009, at 11:27 AM, Jared Gisin wrote: > In order to fire up the app with sane default, I should be able to > issue one command with no arguments as the defaults for all of those > should be baked into the system. [snip] > I guess in the mean time, I'll just write my own custom > Se

Re: [Twisted-Python] adbapi and multiple queries in single transaction.

2009-06-23 Thread Phil Christensen
On Jun 23, 2009, at 9:45 AM, Vishal Shetye wrote: > I initially thought of putting all the queries per operation in a > runInteraction. However this results in code-duplication as many > queries are shared between different operations. It seems like the easiest way to deal with this would be t

Re: [Twisted-Python] untwisting twistd

2009-06-22 Thread Phil Christensen
On Jun 22, 2009, at 5:38 PM, gl...@divmod.com wrote: > On 09:06 pm, p...@bubblehouse.org wrote: >> Look at the init script used to start MySQL sometime, particularly >> when installed from a package on a finicky distro like debian. Or >> Apache. Or bind. Or any one of a number of other complex

Re: [Twisted-Python] untwisting twistd

2009-06-22 Thread Phil Christensen
On Jun 22, 2009, at 4:30 PM, Jared Gisin wrote: > Which is iditic as my application may not even expose a –pidfile or > a –logfile and it’s definatley not called twistd. The platform > specific application runners need to be more generalized so users > can write their own twistd equivalent to

Re: [Twisted-Python] Twisted perspective broker on port 80, problem

2009-06-17 Thread Phil Christensen
On Jun 17, 2009, at 4:32 PM, hbd wrote: > Is there any reason why I am getting this error when I try to get > perspective broker to be on port 80? > > twisted.internet.error.CannotListenError: Couldn't listen on any:80: > (13, 'Permission denied'). > > I made sure port 80 was not used by Apache or

Re: [Twisted-Python] Consistent interfaces to asynchronous partially-available services using Deferreds and state machines (was Re: Another approach to allowing __init__ to work with Deferreds)

2009-05-21 Thread Phil Christensen
On May 20, 2009, at 6:10 PM, Tristan Seligmann wrote: > On Tue, May 12, 2009 at 1:39 PM, Terry Jones wrote: >> If Python allowed me to return a deferred from __init__, my problem >> would >> vanish. That's not going to happen though, I know :-) > > Well, if you /really/ want to, you can impleme

Re: [Twisted-Python] Consistent interfaces to asynchronous partially-available services using Deferreds and state machines (was Re: Another approach to allowing __init__ to work with Deferreds)

2009-05-14 Thread Phil Christensen
On May 14, 2009, at 4:01 AM, Terry Jones wrote: "Phil" == Phil Christensen writes: Phil> I don't know if I agree with the need for such a feature (that is, Phil> deferred __init__ usage), but it was a very interesting coding Phil> challenge I wanted to take a wha

Re: [Twisted-Python] Consistent interfaces to asynchronous partially-available services using Deferreds and state machines (was Re: Another approach to allowing __init__ to work with Deferreds)

2009-05-12 Thread Phil Christensen
On May 12, 2009, at 10:47 AM, Phil Christensen wrote: I don't know if I agree with the need for such a feature (that is, deferred __init__ usage), but it was a very interesting coding challenge I wanted to take a whack at. I *think* I might have found a solution, but I don't know i

Re: [Twisted-Python] Consistent interfaces to asynchronous partially-available services using Deferreds and state machines (was Re: Another approach to allowing __init__ to work with Deferreds)

2009-05-12 Thread Phil Christensen
On May 12, 2009, at 7:39 AM, Terry Jones wrote: >> Just as a point of convenience, I would have automatically >> determined this >> list of method names by using a decorator or something. Having it >> as a >> static list in the method invocation seems to me like it would be >> very easy >> t

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

2009-01-26 Thread Phil Christensen
On Jan 26, 2009, at 8:00 AM, Alessio Pace wrote: The point is that I must assure multiple test classes have their test methods run within an active reactor. So somewhere a reactor.run() has to be called.. Necessarily, if I want that my tests battery to terminate, a reactor.stop() must be inv

Re: [Twisted-Python] Tracebacks being dropped from exceptions when using inlineCallbacks

2009-01-16 Thread Phil Christensen
On Jan 12, 2009, at 8:36 PM, Terry Jones wrote: I think I've finally gotten to the bottom of why exceptions sometimes lose their tracebacks when using inlineCallbacks. [snip] We make a failure object, it has a traceback, but after passing it to the errback method on a deferred the tracebac

Re: [Twisted-Python] Tracebacks being dropped from exceptions when using inlineCallbacks

2009-01-12 Thread Phil Christensen
On Jan 12, 2009, at 8:36 PM, Terry Jones wrote: I think I've finally gotten to the bottom of why exceptions sometimes lose their tracebacks when using inlineCallbacks. [snip snip] I'll stop for now. I have some suggestions for fixes, but I'm already in over my head. BTW, I get the impressi

Re: [Twisted-Python] spawnProcess help needed

2008-12-10 Thread Phil Christensen
On Dec 9, 2008, at 5:41 PM, Jean-Paul Calderone wrote: On Tue, 9 Dec 2008 15:43:00 -0500, Phil Christensen <[EMAIL PROTECTED] > wrote: Everything is basically working, except for the fact that the md5sum processes never go away. It does seem that processEnded is being called, since

[Twisted-Python] spawnProcess help needed

2008-12-09 Thread Phil Christensen
Hello All- I'm running into an issue with a project I'm working on that involves coordinating a large number of external processes to encode audio into different formats, and do other bookkeeping. I seem to be having a problem when I use spawnProcess to call the md5sum binary. The process