Skip to content
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

executablePath returns invalid path just after a new version has been published #4091

Closed
robertherber opened this issue Mar 1, 2019 · 4 comments

Comments

@robertherber
Copy link

Steps to reproduce

  • Puppeteer version: 1.12.2
  • Platform / OS version: MacOS 10.14.3
  • Node.js version: v10.5.0

What steps will reproduce the problem?

This has happened to me two times now. I've managed to install puppeteer right after a new version has been published. I'm pretty sure there's an issue with the publishing process. executablePath returned three different values during the last hour:
node_modules/puppeteer/.local-chromium/mac-594312/chrome-mac/Chromium.app/Contents/MacOS/Chromium
node_modules/puppeteer/.local-chromium/mac-624487/chrome-mac/Chromium.app/Contents/MacOS/Chromium
node_modules/puppeteer/.local-chromium/mac-624492/chrome-mac/Chromium.app/Contents/MacOS/Chromium

And this executable path is not always matching the actual path of the downloaded browser - it's pointing to a non-existent directory.

What is the expected result?
It should point to the executable path of the browser.

What happens instead?
It returns a non-existent/invalid path.

@aslushnikov
Copy link
Contributor

@robertherber executablePath is affected by the PUPPETEER_EXECUTABLE_PATH and PUPPETEER_CHROMIUM_REVISION env variables.

Can it be the reason for your behavior?

@robertherber
Copy link
Author

Hi @aslushnikov,

I've never touched those environment variables, so I don't think that's the reason. Now it's suddenly back at mac-594312 which it was trying to run an hour ago - which is not the correct path. This time I'm pretty sure I haven't even touched node_modules - so I really don't understand what's triggering this..

@aslushnikov
Copy link
Contributor

@robertherber the other suggestion is that something finicky going on with your node_modules/. Looks like there are multiple versions installed and your require resolves to either of them.

The 594312 is a Puppeteer v1.9.0. Can you please do the following:

console.log('Required puppeteer version is: ' + require('puppeteer/package.json').version);

and tell me what it prints?

@robertherber
Copy link
Author

@aslushnikov Ah, there we got it! There was a hackish postinstall script running wild resetting it to 1.9.0. Thanks man. You can close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants