Forums

Python module "tweepy" not working.

When I try to run my script, I get the following error

Traceback (most recent call last): File "/home/generationxzy/test.py", line 104, in <module> stream.filter(track=['@replybotxzy']) File "/usr/local/lib/python2.7/dist-packages/tweepy/streaming.py", line 316, in filter self._start(async) File "/usr/local/lib/python2.7/dist-packages/tweepy/streaming.py", line 237, in _start self._run() File "/usr/local/lib/python2.7/dist-packages/tweepy/streaming.py", line 157, in _run conn.connect() File "/usr/lib/python2.7/httplib.py", line 1172, in connect self.timeout, self.source_address) File "/usr/lib/python2.7/socket.py", line 571, in create_connection raise err socket.error: [Errno 111] Connection refused

any help?

Hi there, tweepy doesn't support proxy servers correctly, so it won't work on free accounts. http://stackoverflow.com/questions/14424408/connection-refused-to-twitter-api-on-pythonanywhere

Hey there, I manage a few Twitter bots using the Python-Twitter library worked fine on a free account here. I had to include the library code myself since it's not included on Python Anywhere which isn't a big deal. Of course if you are planning on running more than 2.. I suggest upgrading to the hacker plan for unlimited consoles.

Thanks for the pointer to Python-Twitter, @jerritanderson -- is it this one? Let us know, and if we can we'll see if we can get it into the default installs.

Yes the exact one I am currently using :)

Awesome, thanks!

Do you know how I would stream tweets with "python-twitter"?

Umm this is an example of someone using the Python-Twitter library for a bot. Sure you can re-purpose the code gives you enough starting code https://github.com/rhiever/twitter-follow-bot/blob/master/twitter_follow_bot.py