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.

[Bug] Puppeteer downloading

See original GitHub issue

Describe the bug

The browser downloads each installation with such dependencies (attached below); even if I don’t want to load puppeteer-extra

It’s ~500 mb, which are built in lambda every time, which adds some complexity

Code Snippet

> npm i
// with:
"dependencies": {
	"@sparticuz/chrome-aws-lambda": "^14.4.1",
	"playwright-core": "^1.24.0-alpha-jul-6-2022",
	"puppeteer-extra-plugin-stealth": "^2.10.2"
},

Versions

> npm list
+-- @sparticuz/chrome-aws-lambda@14.4.1
+-- playwright-core@1.24.0-alpha-jul-6-2022
+-- puppeteer-extra-plugin-stealth@2.10.2

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
berstendcommented, Jul 7, 2022

ah, puppeteer-extra-plugin-stealth has puppeteer-extra-plugin as a dependency which lists puppeteer-extra as a peer dependency which lists puppeteer as a peer dependency.

Seems like peer dependencies are automatically installed, that behavior changed at some point if I recall correctly.

Will remove those peer dependencies or mark them as optional.

Quick fix: set PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true

0reactions
b5414commented, Jul 8, 2022

Very nice, thank you 😘

Read more comments on GitHub >

github_iconTop Results From Across the Web

Chrome download error when downloading file with ...
I want to run this with Puppeteer. Problem is that the CSV is downloaded empty and with an error. This happens both with...
Read more >
[Bug]: File gets downloaded in headless:false but not ...
Bug description A PDF file when tried to download via headless:false mode, ... Puppeteer version puppeteer-extra(3.1.16) Node.js ...
Read more >
Puppeteer documentation
puppeteer is a product for browser automation. When installed, it downloads a version of Chromium, which it then drives using puppeteer-core .
Read more >
puppeteer-core
puppeteer is a product for browser automation. When installed, it downloads a version of Chromium, which it then drives using puppeteer-core .
Read more >
49621 (Travis: Download Chromium for e2e tests only)
puppeteer @2.1.1 install /home/travis/build/WordPress/wordpress-develop/node_modules/puppeteer > node install.js ERROR: Failed to download Chromium r722234!
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