GeneralMills / pytrends

Pseudo API for Google Trends
Other
3.27k stars 821 forks source link

'TrendReq' object has no attribute 'realtime_trending_searches' #450

Open OlegRuban-ai opened 3 years ago

OlegRuban-ai commented 3 years ago

The repository says that a method for finding trends in real time has been added. But when you try to check-an error: 'TrendReq' object has no attribute 'realtime_trending_searches'

My version of pytrends is 4.7.3

emlazzarin commented 2 years ago

Why are you overwriting the pytrends module? Could you choose an appropriate variable name and report back?

On Mon, May 23, 2022 at 5:10 AM, nittolese < @.*** > wrote:

@ emlazzarin ( https://github.com/emlazzarin ) any ideas? I am getting this error too. This is what I am doing using code from README. md ( http://readme.md/ )

from pytrends.request import TrendReq pytrends = TrendReq(hl='en-US', tz=360) pytrends.realtime_trending_searches(pn='US')

But I get this:


AttributeError Traceback (most recent call last)

in ----> 1 pytrends.realtime_trending_searches(pn='US') AttributeError: 'TrendReq' object has no attribute 'realtime_trending_searches' The curious thing is that if you initialize the class TrendReq ( request. py ( https://github.com/GeneralMills/pytrends/blob/master/pytrends/request.py ) ) in a shell, then this will work. pytrends = TrendReq(hl='en-US', tz=360) pytrends.realtime_trending_searches(pn='US') — Reply to this email directly, view it on GitHub ( https://github.com/GeneralMills/pytrends/issues/450#issuecomment-1134399124 ) , or unsubscribe ( https://github.com/notifications/unsubscribe-auth/AAIWU4P7L445XD3DJZE5FKLVLNDO3ANCNFSM4VM772SQ ). You are receiving this because you were mentioned. Message ID: