Re: [Twisted-Python] spawnProcess and when to kill

2012-11-27 Thread Itamar Turner-Trauring
On Tue, Nov 27, 2012 at 8:59 AM, 黄 轶明 wrote: > > class Factory(ServerFactory): > ... > > def StopFactory(self): > # which is the p above > p.transport.signalProcess("KILL") > > I thought the subprocess will be killed which is not. > > > What's wrong with my code? Thanks! > Perhaps StopFactory

Re: [Twisted-Python] spawnProcess and when to kill

2012-11-27 Thread 黄 轶明
hi, JP I post the same question on stackoverflow, and my network has some problem yesterday, so I don't know if I send the email success or not. Please accept my pologize. 黄 轶明 mail: hoos...@gmail.com phone: 18620129285 在 2012-11-28,上午9:52,exar...@twistedmatrix.com 写道: > On 27 Nov, 01:59 p

Re: [Twisted-Python] spawnProcess and when to kill

2012-11-27 Thread exarkun
On 27 Nov, 01:59 pm, hoos...@gmail.com wrote: >hi, all > >I start a process using spawnProcess and want to kill when my certain >Factory stops. > >something I wrote like these Hi, Please don't double-post and please don't reply to another message when starting a new topic. Thanks. Jean-Pa

[Twisted-Python] spawnProcess and when to kill

2012-11-27 Thread 黄 轶明
hi, all I start a process using spawnProcess and want to kill when my certain Factory stops. something I wrote like these -- p = SomeProtocol(ProcessProtocol) reactor.spawnProcess(p, 'twistd', ['twistd', '-y', 'anotherMain.py'], {}) -- class Factory(ServerFactory): ...