-
Notifications
You must be signed in to change notification settings - Fork 9.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix executablePath (arm64) #6495
Conversation
alex2844
commented
Oct 9, 2020
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here with What to do if you already signed the CLAIndividual signers
Corporate signers
ℹ️ Googlers: Go here for more info. |
@googlebot I signed it! |
console.error(`If you are on Ubuntu, you can install with: `); | ||
console.error(`\n apt-get install chromium-browser\n`); | ||
throw new Error(); | ||
fs.stat('/usr/bin/chromium', function (err, stats) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(I'm not familiar with arm64) why would it maybe be in chromium-browser or chromium? Should we update the error message too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jackfranklin The error was updated
Suggested commit message:
|
@alex2844 Could you please run Then we can merge this! |
Any way to get movement on this with a release? ❤️ |
+1 for this, willing to help @alex2844 get this over the line if necessary |
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter. We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the ℹ️ Googlers: Go here for more info. |
@googlebot I consent. |
All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter. We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the ℹ️ Googlers: Go here for more info. |
I’ll go ahead and land this, and will fix any remaining lint issues as a follow-up. Thanks, everyone! |
This will fix Apple M1 machines once puppeteer/puppeteer#6495 lands
I still have issues installing puppeteer on M1 Mac since it's looking for the the executable to be in |
I added the following to
...and then used diff --git a/node_modules/puppeteer/lib/cjs/puppeteer/node/Launcher.js b/node_modules/puppeteer/lib/cjs/puppeteer/node/Launcher.js
index 835c74c..1d6e940 100644
--- a/node_modules/puppeteer/lib/cjs/puppeteer/node/Launcher.js
+++ b/node_modules/puppeteer/lib/cjs/puppeteer/node/Launcher.js
@@ -72,7 +72,7 @@ class ChromeLauncher {
let chromeExecutable = executablePath;
if (!executablePath) {
if (os.arch() === 'arm64') {
- chromeExecutable = '/usr/bin/chromium-browser';
+ chromeExecutable = '/opt/homebrew/bin/chromium';
}
else {
const { missingText, executablePath } = resolveExecutablePath(this); |
Is there a reason for not using an environment variable before the hardcoded path suggested by Homebrew? Chromium can be installed without using Homebrew, can it not?
|
@phcoliveira, to me this looks great! Want to do a PR and see if the maintainers agree? |