alexmercerind/youtube-search-python

Relevant Searches not coming up

Closed this issue · 2 comments

Hi, so i tried this library for scraping purposes and it has been very useful! Thanks for this! Since the official apis are so much rate limited its impossible to try on certain use cases.

But lately what i found is that the when i set the VideoSortOrder to relevance, relevant videos are not coming up. The search listing is coming up different than what youtube shows in an incognito tab for the same keyword. The results are ditto when i set the VideoSortOrder to uploadDate would it possible for you to see this ? I think its a bug.

mytja commented

Hey.
Sorry for the delay. I will have a look at this soon...

mytja commented

Hello!
So, I have looked into it, and when request is made officialy (through YouTube), there are many more preferences that are sent from client to server, including your IP address. So, because we aren't sending those, this is why it's probably different. You will get different results if you are in incongito mode, you have different IP address and if you are logged in/logged out. If we would want exactly same results as in your tab, you would have to have exactly same User-Agent & all of those fields. This is kinda complex.
I personally won't have a further look at it, since it's not anything fatal, but you may try to create a PR if you want.
Thanks for your time & have a nice day