From 61756b1fe0215873eeba7fa031f6136004f09527 Mon Sep 17 00:00:00 2001 From: Vukosi Date: Sun, 8 Jan 2017 06:40:15 +0200 Subject: [PATCH] Update twitter API version This will stop the error for "Unknown URL". API endpoint has been updated. --- assignment1/twitterstream.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assignment1/twitterstream.py b/assignment1/twitterstream.py index 147754ac..9e2bcd20 100644 --- a/assignment1/twitterstream.py +++ b/assignment1/twitterstream.py @@ -51,7 +51,7 @@ def twitterreq(url, method, parameters): return response def fetchsamples(): - url = "https://stream.twitter.com/1/statuses/sample.json" + url = "https://stream.twitter.com/1.1/statuses/sample.json" parameters = [] response = twitterreq(url, "GET", parameters) for line in response: