From 914d9d5cc01de89abae982bc2ba255bdb7b42209 Mon Sep 17 00:00:00 2001 From: Josh Roesslein Date: Thu, 17 Sep 2009 18:45:34 -0500 Subject: [PATCH] Added retweet streaming method. --- CHANGES | 1 + ROADMAP | 2 +- tweepy/streaming.py | 7 +++++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index 6a79644..357a440 100644 --- a/CHANGES +++ b/CHANGES @@ -6,6 +6,7 @@ during upgrade will be listed here. + Fixes + Google App Engine fixes (thanks Thomas Bohmbach, Jr) + Added Retweet API methods ++ Added Retweet Streaming method 1.0 -> 1.0.1 ============ diff --git a/ROADMAP b/ROADMAP index b76fe1c..40464e2 100644 --- a/ROADMAP +++ b/ROADMAP @@ -4,5 +4,5 @@ The plan of attack for the next version of Tweepy. ============ + implement win32 file locking for FileCache + add retweet API methods [DONE] -+ add retweet streaming method ++ add retweet streaming method [DONE] diff --git a/tweepy/streaming.py b/tweepy/streaming.py index 947d633..738d05e 100644 --- a/tweepy/streaming.py +++ b/tweepy/streaming.py @@ -151,6 +151,13 @@ class Stream(object): self.running = True Thread(target=self._run).start() + def retweet(self): + if self.running: + raise TweepError('Stream object already connected!') + self.url = '/%i/statuses/retweet.json?delimited=length' % STREAM_VERSION + self.running = True + Thread(target=self._run).start() + def sample(self, count=None): if self.running: raise TweepError('Stream object already connected!') -- 2.25.1