[Tutor] Responding Tweet: A Twitter Bot
Zaki Akhmad
zakiakhmad at gmail.com
Fri Feb 21 04:52:58 CET 2014
On Thu, Feb 20, 2014 at 7:39 PM, James Scholes <james at jls-radio.com> wrote:
> Most decent Python libraries for accessing Twitter support the streaming
> API. This lets you keep a connection to the Twitter API alive and
> process new data as it is received. There is a simple (but out-of-date)
> example on using streaming with the twitter package you linked to:
> https://pypi.python.org/pypi/twitter/1.13.1
My question is: how to execute this streaming API?
My current approach is using cron to execute python script which has
"check the streaming API" function:
def check_mention:
if (mention):
tweet
If I want to check every minute, then I should configure cron to
execute this script every minute. Are there any other approach besides
using cron?
--
Zaki Akhmad
More information about the Tutor
mailing list