提问人:Jhonnas 提问时间:10/14/2023 更新时间:10/14/2023 访问量:90
将 PUPPETEER 安装为依赖项时出现问题 - VPS UBUNTU 20.04 上的节点 .js
Problems installing PUPPETEER as a dependency - node.js on a VPS UBUNTU 20.04
问:
我使用 npm install 来安装我的项目的依赖项,但它不允许我安装 puppeteer。
npm ERR! command failed
npm ERR! command sh -c node install.js
npm ERR! ERROR: Failed to set up Chrome r115.0.5790.98! Set "PUPPETEER_SKIP_DOWNLOAD" env variable to skip download.
npm ERR! Error: Download failed: server returned code 403. URL: https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/115.0.5790.98/linux64/chrome-linux64.zip
npm ERR! at /var/www/Backend/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js:100:31
npm ERR! at ClientRequest.requestCallback (/var/www/Backend/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js:77:13)
npm ERR! at Object.onceWrapper (node:events:628:26)
npm ERR! at ClientRequest.emit (node:events:513:28)
npm ERR! at HTTPParser.parserOnIncomingClient (node:_http_client:701:27)
npm ERR! at HTTPParser.parserOnHeadersComplete (node:_http_common:119:17)
npm ERR! at TLSSocket.socketOnData (node:_http_client:542:22)
npm ERR! at TLSSocket.emit (node:events:513:28)
npm ERR! at addChunk (node:internal/streams/readable:324:12)
npm ERR! at readableAddChunk (node:internal/streams/readable:297:9)
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2023-10-14T13_15_08_924Z-debug-0.log
我需要安装 puppeteer,我用它来生成 pdf 并通过电子邮件发送,问题是它不允许我安装它,所以我的项目没有上述依赖项。我不知道如何修复这个错误,我已经尝试解决它几天了。
答: 暂无答案
评论