Puppeteer: Error: Could not find Chrome (ver. 113.0.5672.63).

0

In my nodejs project hosted on AWS EC2. I am using puppeteer for converting a html content to PDF using puppeteer. Whenever I try to call the function. I am getting the following error: ``error: Could not find Chrome (ver. 113.0.5672.63). This can occur if either

  1. you did not perform an installation before running the script (e.g. npm install) or
  2. your cache path is incorrectly configured (which is: /root/.cache/puppeteer). For (2), check out our guide on configuring puppeteer at https://pptr.dev/guides/configuration. Error: Could not find Chrome (ver. 113.0.5672.63). This can occur if either
  3. you did not perform an installation before running the script (e.g. npm install) or
  4. your cache path is incorrectly configured (which is: /root/.cache/puppeteer). For (2), check out our guide on configuring puppeteer at https://pptr.dev/guides/configuration. at ChromeLauncher.resolveExecutablePath (/var/app/current/node_modules/puppeteer-core/lib/cjs/puppeteer/node/ProductLauncher.js:301:27) at ChromeLauncher.executablePath (/var/app/current/node_modules/puppeteer-core/lib/cjs/puppeteer/node/ChromeLauncher.js:182:25) at ChromeLauncher.computeLaunchArguments (/var/app/current/node_modules/puppeteer-core/lib/cjs/puppeteer/node/ChromeLauncher.js:98:37) at async ChromeLauncher.launch (/var/app/current/node_modules/puppeteer-core/lib/cjs/puppeteer/node/ProductLauncher.js:83:28)``

I tried different solutions like:

  1. Defining an env variable PUPPETEER_SKIP_DOWNLOAD=true.
  2. upgrading/downgrading node version. Could any please help me out!

My application's production server is getting crashed.

Yusuf
已提問 6 個月前檢視次數 1208 次
1 個回答
0

While trying to run local server. I am getting the following error: SyntaxError: Unexpected token '??=' [1] at wrapSafe (internal/modules/cjs/loader.js:1001:16) [1] at Module._compile (internal/modules/cjs/loader.js:1049:27) [1] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10) [1] at Module.load (internal/modules/cjs/loader.js:950:32) [1] at Function.Module._load (internal/modules/cjs/loader.js:790:14) [1] at Module.require (internal/modules/cjs/loader.js:974:19) [1] at require (internal/modules/cjs/helpers.js:92:18) [1] at Object.<anonymous> (Y:\Code Symphony\one-construction-apis\node_modules\puppeteer-core\lib\cjs\puppeteer\common\HTTPRequest.js:6:19) [1] at Module._compile (internal/modules/cjs/loader.js:1085:14) [1] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)

Yusuf
已回答 6 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南