bernardopires / twitch-chat-logger

A simple app for logging twitch's chat to a PostgreSQL database.
MIT License
60 stars 14 forks source link

Exception when starting (python 2.7, anaconda) #1

Open nevencaplar opened 9 years ago

nevencaplar commented 9 years ago

Hi

I am having problems running the code. After successful installation I get:

2015-08-03 21:19:24,276 - ircconnection.logger - INFO - Setting password
2015-08-03 21:19:24,276 - ircconnection.logger - INFO - Registering nick nevencaplar
2015-08-03 21:19:24,277 - ircconnection.logger - INFO - Authing as nevencaplar
Exception in thread Bot 1:
Traceback (most recent call last):
  File "/home/caplarn/anaconda/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/home/caplarn/twitch-chat-logger/bot.py", line 38, in run
    data = self.conn.get_data()  # returns empty string if times out
  File "/home/caplarn/twitch-chat-logger/src/irckit/irc.py", line 249, in get_data
    data = self._sock_file.readline()
  File "/home/caplarn/anaconda/lib/python2.7/socket.py", line 451, in readline
    data = self._sock.recv(self._rbufsize)
  File "/home/caplarn/anaconda/lib/python2.7/site-packages/gevent/socket.py", line 392, in recv
    self._wait(self._read_event)
  File "/home/caplarn/anaconda/lib/python2.7/site-packages/gevent/socket.py", line 298, in _wait
    self.hub.wait(watcher)
  File "/home/caplarn/anaconda/lib/python2.7/site-packages/gevent/hub.py", line 341, in wait
    result = waiter.get()
  File "/home/caplarn/anaconda/lib/python2.7/site-packages/gevent/hub.py", line 568, in get
    return self.hub.switch()
  File "/home/caplarn/anaconda/lib/python2.7/site-packages/gevent/hub.py", line 331, in switch
    return greenlet.switch(self)
LoopExit: This operation would block forever

I am running Ubuntu 14.04 and (obviously) anaconda python 2.7. I have also checked that I have newest version (1.01) of the package gevent which could possibly be part of the problem.

I am very interested in this program (seems really great) and would appreciate help!

bernardopires commented 9 years ago

I can not reproduce this. Could you try with a fresh python install? I'm not sure how anaconda works, but it might come with packages that are changing how threading is working? Can you uninstall gevent and greenlet?

CBQu commented 7 years ago

Hi,

I am working on a project for analyzing the comments of Twitch. Your work is very helpful. But this happened to me, too.

Exception in thread Bot 0:
Traceback (most recent call last):
  File "/Users/QCb/anaconda/lib/python2.7/threading.py", line 801, in __bootstrap_inner
    self.run()
  File "/Users/QCb/twitch-chat-logger/bot.py", line 38, in run
    data = self.conn.get_data()  # returns empty string if times out
  File "/Users/QCb/twitch-chat-logger/src/irckit/irc.py", line 249, in get_data
    data = self._sock_file.readline()
  File "/Users/QCb/anaconda/lib/python2.7/socket.py", line 451, in readline
    data = self._sock.recv(self._rbufsize)
  File "/Users/QCb/anaconda/lib/python2.7/site-packages/gevent/_socket2.py", line 283, in recv
    self._wait(self._read_event)
  File "/Users/QCb/anaconda/lib/python2.7/site-packages/gevent/_socket2.py", line 182, in _wait
    self.hub.wait(watcher)
  File "/Users/QCb/anaconda/lib/python2.7/site-packages/gevent/hub.py", line 651, in wait
    result = waiter.get()
  File "/Users/QCb/anaconda/lib/python2.7/site-packages/gevent/hub.py", line 899, in get
    return self.hub.switch()
  File "/Users/QCb/anaconda/lib/python2.7/site-packages/gevent/hub.py", line 630, in switch
    return RawGreenlet.switch(self)
LoopExit: ('This operation would block forever', <Hub at 0x106a83cd0 select pending=0 ref=0>)

I am running Mac OS 10.12.3. I have tried reinstall gevent and greenlet. But I still cannot run this program. Do you have any idea for this issue? I really appreciate your help.