From d81f3776ab2a31840701fe22a9a78c15bdf47842 Mon Sep 17 00:00:00 2001 From: Andrei Petre Date: Tue, 10 Jun 2014 02:29:22 +0300 Subject: [PATCH] IdIterator fix TypeError: _call() got multiple values for keyword argument 'max_id'. The problem is that max_id is passed in self.method as param but also kept in kargs. Doing a kargs.pop with None as default value for 'max_id' solves the problem as not keeping 'max_id' in two places anymore. --- tweepy/cursor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tweepy/cursor.py b/tweepy/cursor.py index 1a08cd8..faa3515 100644 --- a/tweepy/cursor.py +++ b/tweepy/cursor.py @@ -84,7 +84,7 @@ class IdIterator(BaseIterator): def __init__(self, method, args, kargs): BaseIterator.__init__(self, method, args, kargs) - self.max_id = kargs.get('max_id') + self.max_id = kargs.pop('max_id', None) self.num_tweets = 0 self.results = [] self.model_results = [] -- 2.25.1