teppyboy / ayayaxyz

A bot for Telegram
MIT License
2 stars 0 forks source link

pixiv: cloudscraper requires paying to solve Cloudflare captcha v2 #4

Closed teppyboy closed 1 year ago

teppyboy commented 1 year ago
cloudscraper.exceptions.CloudflareChallengeError: Detected a Cloudflare version 2 Captcha challenge, This feature is not available in the opensource (free) version.

During handling of the above exception, another exception occurred:

pixivpy3.utils.PixivError: requests POST https://oauth.secure.pixiv.net/auth/token error: Detected a Cloudflare version 2 Captcha challenge, This feature is not available in the opensource (free) version.

During handling of the above exception, another exception occurred:

ayayaxyz.api.pixiv.PixivLoginError: requests POST https://oauth.secure.pixiv.net/auth/token error: Detected a Cloudflare version 2 Captcha challenge, This feature is not available in the opensource (free) version.

along with https://github.com/VeNoMouS/cloudscraper/pull/272#issuecomment-1229160699 and other PRs mentioning "v2" are closed without any answer, it seems that we need to switch to other method to bypass cloudflare.

teppyboy commented 1 year ago

fixed in 0d61f21b6abdd3a6a2f5963c465bea86300076e4 by using ByPassSniApi() to let pixivpy use requests.Session() instead of cloudscraper