yowsup
yowsup copied to clipboard
unhandled <stream:error> exception
hi,
is there any ways how to catch the unhandled exception?
from example i use this simple method to start client
try:
wa = WhatsappListenerClient()
wa.login(login, password)
except Exception, e:
print("Exception: %s") % str(e)
but i cannot catch this following error / exception, no onDisconnect event is trigered
ReaderThread: Waiting, time to die: T-150 seconds
ReaderThread: Waiting, time to die: T-120 seconds
BinTreeNodeReader: Incoming
BinTreeNodeReader:
<stream:error>
<ack>
</ack>
</stream:error>
Exception in thread Thread-682:
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner
self.run()
File "/usr/local/lib/python2.7/dist-packages/Yowsup/connectionmanager.py", line 896, in run
except FatalStreamErrorException, e:
NameError: global name 'FatalStreamErrorException' is not defined
if you created new exception type you must define it first
@CODeRUS
i don't define new exception, it seems FatalStreamErrorException is from pulled source that i merge with tgalal source.
on my side stream error is very annoying, i cannot catch because after this error showed up the client is stuck (doesn't sent disconnected signal)
<stream:error>
<ack>
</ack>
</stream:error>
I've dealt it this way: #1535