like-gold•2y ago
Added "playwright-extra" with "stealthPlugin" and got error "Cannot read properties of undefined"
I have some code using PlaywrightCrawler. I added "playwright-extra" with "stealthPlugin" to this code. Exactly as in documentation [1]
I added to my code only this:
The rest of program remains the same as before. And I have
useFingerprints: true
and launcher: firefox
in code.
Well, the code works. Bot detection sites report that my crawler has 3 plugins and supports 4 mime types, so something changed.
But! I got this is the stdout:
How bad is this?
[1] https://crawlee.dev/docs/examples/crawler-pluginsUsing puppeteer-extra and playwright-extra | Crawlee
puppeteer-extra and playwright-extra are community-built
8 Replies
like-goldOP•2y ago
Is it something related to versions of libraries?
here the output of npm ls:
pls help, this exception still there...
You are mixing Playwright and Puppeteer, use just one
xenial-black•2y ago
Getting the same error using playwright-extra but doesnt really effect anything, everything continues to work as normal
I think puppeteer-extra plugin simply does not work with firefox. As puppeteer is chrome only, this works with playwright - chrome setting.
this works without errors
But sadly still blocked on sites like g2.com or bigspy.com but could help on some other sites.
xenial-black•2y ago
Yup its only effecting firefox https://github.com/berstend/puppeteer-extra/issues/576
GitHub
[Bug] stealth plugin on Firefox throw `TypeError: Cannot read prope...
Steps to reproduce: in a new node project, run PUPPETEER_PRODUCT=firefox npm install puppeteer puppeteer-extra puppeteer-extra-plugin-stealth run the following script: import puppeteer from 'pu...
xenial-black•2y ago
It looks like I have to use the stealth plugin in order to bypass cloudflare captchas using firefox. I thought crawlee already implemented all of the features from the stealth plugin but it wont bypass cloudflare cpatchas on firefox without it. What does the stealth plugin have that crawlee doesnt?
xenial-black•2y ago
I'd also like to know this! I'm fully blocked on Indeed.com regardless of implimentation.
like-goldOP•11mo ago
Well (almost a year later, I admit it), I did some clean-up in package.json (no puppeteer any more):
And I do this in code:
firefox.use(stealthPlugin());
And it does not work, same error as before:
Just in case all this stuff is still relevant - would be great to fix it. Would you pls look @Lukas Krivka ?