def success(name,tme):
global count
# Splits the time duration into relevant information
d,waste1,waste2 = tme.split()
d=eval(d)
# runs when needs to make STREAMLISTENER API Calls
if d>7:
twitter_stream = Stream(auth, MyListener(time_limit=d))
twitter_stream.filter(track=[name])
else:
# runs when needs to make REST API Calls
past(name,d)
return render_template('welcome.html',count=count,name=name,duration=tme)
# collects the input data from the FORM and then redirects the input to the next page
评论列表
文章目录