Commit d81f3776 authored by Andrei Petre's avatar Andrei Petre
Browse files

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.
parent 4c9c58f1
...@@ -84,7 +84,7 @@ class IdIterator(BaseIterator): ...@@ -84,7 +84,7 @@ class IdIterator(BaseIterator):
def __init__(self, method, args, kargs): def __init__(self, method, args, kargs):
BaseIterator.__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.num_tweets = 0
self.results = [] self.results = []
self.model_results = [] self.model_results = []
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment