KeyError on worker shutdown sometimes
moshez opened this issue · 0 comments
This exception pops up somewhat often:
2010-05-12 11:31:23-0400 [-] Unhandled error in Deferred:
2010-05-12 11:31:23-0400 [-] Unhandled Error
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/ses-181-py2.6.egg/ses/email_client.py", line 342, in scrapeURL
d = self._pool.callRemote(ScrapeURL, url=url)
File "/usr/lib/python2.6/site-packages/ampoule-0.2.0-py2.6.egg/ampoule/pool.py", line 286, in callRemote
return self.doWork(*args, **kwargs)
File "/usr/lib/python2.6/site-packages/ampoule-0.2.0-py2.6.egg/ampoule/pool.py", line 299, in doWork
self._cb_doWork(command, _d=d, **kwargs)
File "/usr/lib/python2.6/site-packages/ampoule-0.2.0-py2.6.egg/ampoule/pool.py", line 278, in _cb_doWork
return defer.maybeDeferred(child.callRemote, command, **kwargs
--- ---
File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux-i686.egg/twisted/internet/defer.py", line 117, in maybeDeferred
result = f(*args, **kw)
File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux-i686.egg/twisted/protocols/amp.py", line 802, in callRemote
return co._doCommand(self)
File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux-i686.egg/twisted/protocols/amp.py", line 1686, in _doCommand
self.requiresAnswer)
File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux-i686.egg/twisted/protocols/amp.py", line 733, in _sendBoxCommand
box._sendTo(self.boxSender)
File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux-i686.egg/twisted/protocols/amp.py", line 558, in _sendTo
proto.sendBox(self)
File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux-i686.egg/twisted/protocols/amp.py", line 2007, in sendBox
self.transport.write(box.serialize())
File "/usr/lib/python2.6/site-packages/ampoule-0.2.0-py2.6.egg/ampoule/main.py", line 76, in write
self.transport.writeToChild(TO_CHILD, data)
File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux-i686.egg/twisted/internet/process.py", line 684, in writeToChild
self.pipes[childFD].write(data)
exceptions.KeyError: 3
It may only happen when the worker process exits abnormally, ie after being SIGKILL'd or encountering a platform enforced resource limit.