PUPPETEER_EXECUTABLE_PATH ignored on arm64 machines
See original GitHub issueSteps to reproduce
Tell us about your environment:
- Puppeteer version: 8.0.0
- Platform / OS version: MacOS Big Sur (Macbook Air M1)
- URLs (if applicable): -
- Node.js version: 15.11.0
What steps will reproduce the problem?
Please include code that reproduces the issue.
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch();
const page = await browser.newPage();
await page.goto('https://example.com');
await page.screenshot({ path: 'example.png' });
await browser.close();
})();
brew install chromiumnpm install puppeteer- Save the above script as
index.js PUPPETEER_EXECUTABLE_PATH="/opt/homebrew/bin/chromium" node index.js
What is the expected result?
It should try to use /opt/homebrew/bin/chromium as the path to the browser executable.
What happens instead?
Puppeteer always overwrites the executable path specified via the environment variable internally and falls back to /usr/bin/chromium-browser. Setting executablePath explicitly in launch options works though:
// works, only setting via env var doesn't work
await puppeteer.launch({ executablePath: "/opt/homebrew/bin/chromium" });
Issue Analytics
- State:
- Created 3 years ago
- Reactions:28
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Troubleshooting - Puppeteer
Make sure all the necessary dependencies are installed. You can run ldd chrome | grep not on a Linux machine to check which...
Read more >Failed Puppeteer/Chromium installation with Node.js, ARM64 ...
Setting Chromium executablePath. Chromium was installed to /usr/bin/google-chrome-stable on the EC2 instances, but this path doesn't ...
Read more >Puppeteer documentation - DevDocs
Puppeteer 7.1.0 API documentation with instant search, offline support, keyboard shortcuts, mobile version, and more.
Read more >Practical Puppeteer: Playing with Puppeteer Core package
Get the executable path for Chrome or Chromium browser. On my Ubuntu machine, I just type this. whereis google-chrome-stable.
Read more >How to fix M1 Mac Puppeteer chromium arm64 bug
The chromium binary is not available for arm64: If you are on Ubuntu, you can install with: apt-get install chromium-browser path-to-project/node_modules/ ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

ping (to avoid stale bot)
This same on PuppeteerSharp 8.0.0 and Google Chrome 100.0.4896.127-1