hharnisc / python-meteor

A meteor client for python

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

socket close problem

retobaettig2 opened this issue · comments

Hi

1st of all: Thanks for the great package!
I have one small problem: After some time it can happen that the socket ist closed in this case, python-meteor stops working with the follwing trace:

No handlers could be found for logger "ws4py"
Exception in thread WebSocketClient:
Traceback (most recent call last):
  File "C:\Python27\lib\threading.py", line 801, in __bootstrap_inner
    self.run()
  File "C:\Python27\lib\threading.py", line 754, in run
    self.__target(*self.__args, **self.__kwargs)
  File "C:\Python27\lib\site-packages\ws4py\websocket.py", line 430, in run
    self.terminate()
  File "C:\Python27\lib\site-packages\ws4py\websocket.py", line 327, in terminate
    self.closed(1006, "Going away")
  File "C:\Python27\lib\site-packages\DDPClient.py", line 30, in closed
    self.emit('closed', code, reason)
  File "C:\Python27\lib\site-packages\pyee\__init__.py", line 113, in emit
    f(*args, **kwargs)
  File "C:\Python27\lib\site-packages\DDPClient.py", line 152, in closed
    self.emit('socket_closed', code, reason)
  File "C:\Python27\lib\site-packages\pyee\__init__.py", line 113, in emit
    f(*args, **kwargs)
  File "C:\Users\reto_000\Dropbox\Development\htdocs\WebPLC\python_client\MeteorClient.py", line 320, in closed
    self.emit('closed', code, reason)
  File "C:\Python27\lib\site-packages\pyee\__init__.py", line 113, in emit
    f(*args, **kwargs)
TypeError: closed() takes exactly 3 arguments (2 given)

lookes to me like the self.emit('closed', code, reason) would need a 3rd argument?!?

Thanks in advance,

Reto