Xewdy444 / Playwright-reCAPTCHA

A Python library for solving reCAPTCHA v2 and v3 with Playwright
https://pypi.org/project/playwright-recaptcha/
MIT License
243 stars 34 forks source link

Is this library firefox browser only, and not compatible with webkit and chromium browsers? I tried both of them and they failed to work. #50

Closed YonQua closed 1 year ago

YonQua commented 1 year ago

Is this library firefox browser only, and not compatible with webkit and chromium browsers? I tried both of them and they failed to work.

Xewdy444 commented 1 year ago

Works for all browsers.

YonQua commented 1 year ago

from playright.sync_api import sync_playwright from playwright_recaptcha import recaptchav2

with sync_playwright() as playwright: browser = playwright.firefox.launch() page = browser.new_page() page.goto("https://www.google.com/recaptcha/api2/demo")

with recaptchav2.SyncSolver(page) as solver:
    token = solver.solve_recaptcha(wait=True)
    print(token)

 I tested with your example, I just changed the default firefox to webkit and chromium, and they didn’t work. I also used await self.page.pause() to follow up, and it kept looping until it timed out.
Xewdy444 commented 1 year ago

Can you please explain what you mean when you say they didn't work.

YonQua commented 1 year ago
image image
Xewdy444 commented 1 year ago

English is the only supported language currently.