Inherent asyncore.dispatcher_with_send exception

N

nobody

Hi,

I have a class ClientHandler(asyncore.dispatcher_with_send), it was runningfine without calling any of my own classes. But it got following exceptionwhen I called my own class GetMyResponse inside the def handle_read(self).Not sure why it causes disturbance to asyncore.dispatcher_with_send __init__ when calling an extra class? Appreciate any clues and tips.

class GetMyResponse:
def __init__(self, message):
....

class ClientHandler(asyncore.dispatcher_with_send):
def handle_read(self):
....
handleResponse = GetMyResponse(data)
self.send(handleResponse.getResponse())


error: uncaptured python exception, closing channel <__main__.ClientHandlerconnected 127.0.0.1:42383 at 0x7f3b638b6758> (<type 'exceptions.TypeError'>:__init__() takes exactly 4 arguments (3 given) [/usr/lib64/python2.6/asyncore.py|read|78] [/usr/lib64/python2.6/asyncore.py|handle_read_event|428]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top