We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am trying to use pytrends to get historical data Example: from pytrends.request import TrendReq
pytrends = TrendReq(hl='en-US', tz=360) kw_list = ["HDFC bank"] pytrends.build_payload(kw_list, cat=0, timeframe='today 5-y', geo='', gprop='') pytrends.interest_over_time()
it gives the following error TooManyRequestsError: The request failed: Google returned a response with code 429 How to address this issue?
The text was updated successfully, but these errors were encountered:
Looks like google have upgraded their anti-bot measures. Currently this package is broken :-(
Sorry, something went wrong.
Any other library to scrap the google trends data?
You can try trendspy - it uses a slightly different approach to the API. Install with pip install trendspy.
pip install trendspy
Your code would look like this:
from trendspy import Trends tr = Trends() df = tr.interest_over_time(['HDFC bank'], timeframe='today 5-y')
But keep in mind that if it's a Google-side blocking, it might not help.
With pytrends I can do 30 requests per minute, and with trendspy 49.
No branches or pull requests
I am trying to use pytrends to get historical data
Example:
from pytrends.request import TrendReq
pytrends = TrendReq(hl='en-US', tz=360)
kw_list = ["HDFC bank"]
pytrends.build_payload(kw_list, cat=0, timeframe='today 5-y', geo='', gprop='')
pytrends.interest_over_time()
it gives the following error
TooManyRequestsError: The request failed: Google returned a response with code 429
How to address this issue?
The text was updated successfully, but these errors were encountered: