joaoricardo000 / whatsapp-bot-seed

A small python framework to create a whatsapp bot, with regex-callback message routing.
730 stars 243 forks source link

Error when receive message #87

Open ghost opened 8 years ago

ghost commented 8 years ago

Hello, First i was having AssertionErr then i fixed it from this link by the code: You have to go to /usr/lib/python2.7/ and open the file asyncore.py In the file, find the line 199 and change def loop(timeout=30.0, use_poll=False, map=None, count=None): to def loop(timeout=30.0, use_poll=True, map=None , count=None):

After doing this i am having an Bad filedescriptor``

Err_Log self.stack.loop(timeout=0.5, discrete=0.5) File "/usr/local/lib/python2.7/dist-packages/yowsup/stacks/yowstack.py", line 188, in loop asyncore.loop(*args, **kwargs) File "/usr/lib/python2.7/asyncore.py", line 216, in loop poll_fun(timeout, map) File "/usr/lib/python2.7/asyncore.py", line 145, in poll r, w, e = select.select(r, w, e, timeout) error: (9, 'Bad file descriptor') _server.py_ [INFO][2016-07-09 16:17:42,580] Restarting.. _server.py_ [INFO][2016-07-09 16:17:42,581] ################################################## _server.py_ [INFO][2016-07-09 16:17:42,581] Server started. Phone number: *********** _server.py_ [INFO][2016-07-09 16:17:42,581] ################################################## _server.py_ [ERROR][2016-07-09 16:17:42,581] Unexpected Exception: Traceback (most recent call last): File "src/server.py", line 38, in start self.stack.loop(timeout=0.5, discrete=0.5) File "/usr/local/lib/python2.7/dist-packages/yowsup/stacks/yowstack.py", line 188, in loop asyncore.loop(*args, **kwargs) File "/usr/lib/python2.7/asyncore.py", line 216, in loop poll_fun(timeout, map) File "/usr/lib/python2.7/asyncore.py", line 145, in poll r, w, e = select.select(r, w, e, timeout) error: (9, 'Bad file descriptor') _server.py_ [INFO][2016-07-09 16:17:42,582] Restarting.. _server.py_ [INFO][2016-07-09 16:17:42,582] ####################################

ghost commented 8 years ago

The fix that you quoted is for Bad file descriptor

ghost commented 8 years ago

So, what should i do ?

ghost commented 8 years ago

Are you sure that you modified /usr/lib/python2.7/asyncore.py?

ghost commented 8 years ago

yea i did

ghost commented 7 years ago

What to do ?