question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

puppeteer-extra-plugin-recaptcha doesn't work on crunchyroll or Tidal

See original GitHub issue

I can’t get the recaptcha plug in to work on crunchyroll or Tidal. Here’s my example code for Tidal. It’s showing that there’s no captcha on the page when it is clearly there in an iframe.

const puppeteer = require('puppeteer-extra')

// add recaptcha plugin and provide it your 2captcha token
// 2captcha is the builtin solution provider but others work as well.
const RecaptchaPlugin = require('puppeteer-extra-plugin-recaptcha')
puppeteer.use(
  RecaptchaPlugin({
    provider: { id: '2captcha', token: 'XXXXXXX' },
    visualFeedback: true, // colorize reCAPTCHAs (violet = detected, green = solved)
  })
)

puppeteer.launch({ headless: false }).then(async (browser) => {
  const page = await browser.newPage()
  await page.goto('https://my.tidal.com/login')
  await page.waitFor('[value="Log in"]')
  // const loginBtn = '[value="Log in"]'
  // await page.evaluate((loginBtn) => document.querySelector(loginBtn).click(), loginBtn)
  await page.click('[value="Log in"]')
  await page.waitFor('input[id="email"]')
  await page.waitFor(5000)
  await page.type('input[id="email"]', 'panda@yahoo.com', { delay: 50 })
  await page.click('[id="recap-invisible"]')
  await page.waitFor(10000)
  await page.screenshot({ path: 'tidal-input-username.png' })
  const { captchas, solutions, solved, error } = await page.solveRecaptchas()
  console.log('captchas', captchas)
  console.log('solutions', solutions)
  console.log('solved', solved)
  console.log('error', error)
  await page.waitFor('input[id="password"]')
  await page.waitFor(40000)
  await page.screenshot({ path: 'tidal-solved-captcha.png' })
  await browser.close()
})

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:12 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
berstendcommented, Sep 2, 2020

This might be fixed in puppeteer-extra-plugin-recaptcha@3.1.18 (see #300, #304).

Closing for now, please re-open if the above didn’t fix the issue.

0reactions
psalkowskicommented, Aug 13, 2020

I’m using webpack with latest 3.1.15 version of recaptcha plugin. Unfortunately I faced the same problem. My piece of code:

            const {solved, solutions, captchas, error} = await page.solveRecaptchas();

            if (solved.length || solutions.length || captchas.length || error) {
                console.log('Recaptcha:', {solved, solutions, captchas, error});
                await page.waitForNavigation();
            }

Error: TimeoutError: waiting for function failed: timeout 10000ms exceeded.

The error is not always throwed. Debug shows:

$ DEBUG=puppeteer-extra,puppeteer-extra-plugin:* node ./dist/main.js
  puppeteer-extra-plugin:base:recaptcha Initialized. +0ms
  puppeteer-extra-plugin:recaptcha Initialized {
  visualFeedback: true,
  throwOnError: false,
  provider: { id: '2captcha', token: 'xxxx' }
} +0ms
  puppeteer-extra plugin registered recaptcha +0ms
  puppeteer-extra no dependencies are missing +0ms
  puppeteer-extra orderPlugins:before [ 'recaptcha' ] +0ms
  puppeteer-extra orderPlugins:after [ 'recaptcha' ] +0ms
  puppeteer-extra-plugin:recaptcha solveRecaptchas +0ms
  puppeteer-extra-plugin:recaptcha findRecaptchas +0ms
  puppeteer-extra-plugin:recaptcha hasRecaptchaScriptTag true +0ms
  puppeteer-extra-plugin:recaptcha waitForRecaptchaClient - start 2020-08-13T21:50:01.848Z +0ms
  puppeteer-extra-plugin:recaptcha solveRecaptchas {
  captchas: [],
  solutions: [],
  solved: [],
  error: 'TimeoutError: waiting for function failed: timeout 10000ms exceeded'
} +0ms

What I have found is, the error is thrown when I’m on login page. When I log in, and have sessions stored, then re-launch browser directly on user panel, the error is gone.

Read more comments on GitHub >

github_iconTop Results From Across the Web

puppeteer-extra-plugin-recaptcha - npm
A puppeteer-extra and playwright-extra plugin to solve reCAPTCHAs and hCaptchas automatically.
Read more >
facebook Code Example - Code Grepper
It doesn't seem to be a Python package or a valid path to a data directory. ... Syntax Error: Error: PostCSS plugin tailwindcss...
Read more >
How to Bypass CAPTCHAs With Puppeteer AUTOMATICALLY ...
Topics covered - How to solve/bypass the captcha - What service to use ... started with puppeteer - extra and puppeteer - extra...
Read more >
Experts for swipe cube ads plugin - Linknovate
Name Score News Dailymotion 77.7 8 YouTube 73.8 5 Amazon 59.6 8
Read more >
Rebuild Podcast Republic
Listen to a podcast, please open Podcast Republic app. Available on Google Play Store. Category: Technology · Open in Apple Podcasts ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found