chrome-aws-lambda: Could not find expected browser (chrome) locally. Run `npm install` to download the correct Chromium revision (938248).[BUG]

Could not find expected browser (chrome) locally. Run npm install to download the correct Chromium revision (938248). When using serverless-esbuild plugin with puppeteer.

About this issue

  • Original URL
  • State: open
  • Created 2 years ago
  • Reactions: 5
  • Comments: 16

Most upvoted comments

node node_modules/puppeteer/install.js

I get it to work

node node_modules/puppeteer-core/install.js

version : “chrome-aws-lambda”: “^10.1.0”

node node_modules/puppeteer/install.js

but how to use this?

You execute the js file. Just copy paste the command into your console.

That works locally (telling me the browser is already installed):

➜ git:(main) node node_modules/puppeteer/install.js

Chromium is already in [...]/node_modules/puppeteer/.local-chromium/mac-901912; skipping download.

Still, the error remains on AWS lambda. I can’t run that command there, or can I?

It works for me. Thank you.

node node_modules/puppeteer/install.js

I had the same error. It seems it’s because running this locally requires some additional steps: https://github.com/alixaxel/chrome-aws-lambda/wiki/HOWTO:-Local-Development

This explains why the chromium.executablePath is null, as it is not running in the lambda environment.

It’s a seperate problem but now I’m seeing VAAPI video acceleration not available for swiftshader errors when trying to run the instance.