npm start 到 puppeteer@1.12.2 报错。。。
Created by: Arielce
到 npm start 的时候安装 puppeteer。报错。
I:wechaty-getting-started ce$ npm install
wechaty-getting-started@0.1.0 postinstall /Users/ce/yaowu/wechaty-getting-started check-node-version --node ">= 10"
npm notice created a lockfile as package-lock.json. You should commit this file. added 95 packages from 126 contributors in 8.302s I:wechaty-getting-started ce$ npm start
wechaty-getting-started@0.1.0 start /Users/ce/yaowu/wechaty-getting-started node examples/starter-bot.js
10:32:45 INFO Wechaty start() v0.22.6 is starting... 10:32:45 INFO PuppetManager install(wechaty-puppet-puppeteer@^0.14.1) please wait ... npm:
puppeteer@1.12.2 install /Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer node install.js
npm: ERROR: Failed to download Chromium r624492! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download.
npm: { Error: read ECONNRESET at TLSWrap.onStreamRead (internal/stream_base_commons.js:111:27) -- ASYNC -- at BrowserFetcher. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/lib/helper.js:108:27) at Object. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/install.js:64:16) at Module._compile (internal/modules/cjs/loader.js:689:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) at Module.load (internal/modules/cjs/loader.js:599:32) at tryModuleLoad (internal/modules/cjs/loader.js:538:12) at Function.Module._load (internal/modules/cjs/loader.js:530:3) at Function.Module.runMain (internal/modules/cjs/loader.js:742:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3) errno: 'ECONNRESET', code: 'ECONNRESET', syscall: 'read' }
npm: npm npm: WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of file-box@^0.8.22 but none is installed. You must install peer dependencies yourself. npm npm: WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of wechaty-puppet@^0.14.1 but none is installed. You must install peer dependencies yourself. npm npm: WARN rx-queue@0.6.2 requires a peer of brolog@^1.4.9 but none is installed. You must install peer dependencies yourself.
npm:
npm: npm npm: ERR! code ELIFECYCLE
npm: npm ERR! errno 1
npm: npm
npm: ERR! puppeteer@1.12.2 install: node install.js
npm ERR!
npm: Exit status 1
npm: npm ERR!
npm: npm ERR! Failed at the puppeteer@1.12.2 install script.
npm: npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
{ Error: Command failed: npm install wechaty-puppet-puppeteer@^0.14.1 ERROR: Failed to download Chromium r624492! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download. { Error: read ECONNRESET at TLSWrap.onStreamRead (internal/stream_base_commons.js:111:27) -- ASYNC -- at BrowserFetcher. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/lib/helper.js:108:27) at Object. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/install.js:64:16) at Module._compile (internal/modules/cjs/loader.js:689:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) at Module.load (internal/modules/cjs/loader.js:599:32) at tryModuleLoad (internal/modules/cjs/loader.js:538:12) at Function.Module._load (internal/modules/cjs/loader.js:530:3) at Function.Module.runMain (internal/modules/cjs/loader.js:742:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3) errno: 'ECONNRESET', code: 'ECONNRESET', syscall: 'read' } npm WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of file-box@^0.8.22 but none is installed. You must install peer dependencies yourself. npm WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of wechaty-puppet@^0.14.1 but none is installed. You must install peer dependencies yourself. npm WARN rx-queue@0.6.2 requires a peer of brolog@^1.4.9 but none is installed. You must install peer dependencies yourself.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! puppeteer@1.12.2 install: node install.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the puppeteer@1.12.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
at ChildProcess.exithandler (child_process.js:294:12)
at ChildProcess.emit (events.js:182:13)
at ChildProcess.EventEmitter.emit (domain.js:441:20)
at maybeClose (internal/child_process.js:962:16)
at Socket.stream.socket.on (internal/child_process.js:381:11)
at Socket.emit (events.js:182:13)
at Socket.EventEmitter.emit (domain.js:441:20)
at Pipe._handle.close (net.js:610:12)
killed: false, code: 1, signal: null, cmd: 'npm install wechaty-puppet-puppeteer@^0.14.1 ' } 10:36:53 ERR Wechaty start() exception: Command failed: npm install wechaty-puppet-puppeteer@^0.14.1 ERROR: Failed to download Chromium r624492! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download. { Error: read ECONNRESET at TLSWrap.onStreamRead (internal/stream_base_commons.js:111:27) -- ASYNC -- at BrowserFetcher. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/lib/helper.js:108:27) at Object. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/install.js:64:16) at Module._compile (internal/modules/cjs/loader.js:689:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) at Module.load (internal/modules/cjs/loader.js:599:32) at tryModuleLoad (internal/modules/cjs/loader.js:538:12) at Function.Module._load (internal/modules/cjs/loader.js:530:3) at Function.Module.runMain (internal/modules/cjs/loader.js:742:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3) errno: 'ECONNRESET', code: 'ECONNRESET', syscall: 'read' } npm WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of file-box@^0.8.22 but none is installed. You must install peer dependencies yourself. npm WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of wechaty-puppet@^0.14.1 but none is installed. You must install peer dependencies yourself. npm WARN rx-queue@0.6.2 requires a peer of brolog@^1.4.9 but none is installed. You must install peer dependencies yourself.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! puppeteer@1.12.2 install: node install.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the puppeteer@1.12.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
{ Error: Command failed: npm install wechaty-puppet-puppeteer@^0.14.1 ERROR: Failed to download Chromium r624492! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download. { Error: read ECONNRESET at TLSWrap.onStreamRead (internal/stream_base_commons.js:111:27) -- ASYNC -- at BrowserFetcher. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/lib/helper.js:108:27) at Object. (/Users/ce/yaowu/wechaty-getting-started/node_modules/wechaty/node_modules/puppeteer/install.js:64:16) at Module._compile (internal/modules/cjs/loader.js:689:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) at Module.load (internal/modules/cjs/loader.js:599:32) at tryModuleLoad (internal/modules/cjs/loader.js:538:12) at Function.Module._load (internal/modules/cjs/loader.js:530:3) at Function.Module.runMain (internal/modules/cjs/loader.js:742:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3) errno: 'ECONNRESET', code: 'ECONNRESET', syscall: 'read' } npm WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of file-box@^0.8.22 but none is installed. You must install peer dependencies yourself. npm WARN wechaty-puppet-puppeteer@0.14.6 requires a peer of wechaty-puppet@^0.14.1 but none is installed. You must install peer dependencies yourself. npm WARN rx-queue@0.6.2 requires a peer of brolog@^1.4.9 but none is installed. You must install peer dependencies yourself.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! puppeteer@1.12.2 install: node install.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the puppeteer@1.12.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
at ChildProcess.exithandler (child_process.js:294:12)
at ChildProcess.emit (events.js:182:13)
at ChildProcess.EventEmitter.emit (domain.js:441:20)
at maybeClose (internal/child_process.js:962:16)
at Socket.stream.socket.on (internal/child_process.js:381:11)
at Socket.emit (events.js:182:13)
at Socket.EventEmitter.emit (domain.js:441:20)
at Pipe._handle.close (net.js:610:12)
killed: false, code: 1, signal: null, cmd: 'npm install wechaty-puppet-puppeteer@^0.14.1 ' } I:wechaty-getting-started ce$ sudo npm install wechaty-puppet-puppeteer@^0.14.1 Password:
puppeteer@1.12.2 install /Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer node install.js
ERROR: Failed to download Chromium r624492! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download.
{ Error: EACCES: permission denied, mkdir '/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/.local-chromium'
-- ASYNC --
at BrowserFetcher. (/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/lib/helper.js:108:27)
at Object. (/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/install.js:64:16)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)
errno: -13,
code: 'EACCES',
syscall: 'mkdir',
path:
'/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/.local-chromium' }
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! puppeteer@1.12.2 install: node install.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the puppeteer@1.12.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in: npm ERR! /Users/ce/.npm/_logs/2019-02-21T02_48_40_598Z-debug.log I:wechaty-getting-started ce$ npm install puppeteer@1.12.2 npm WARN checkPermissions Missing write access to /Users/ce/yaowu/wechaty-getting-started/node_modules/tough-cookie/node_modules npm WARN checkPermissions Missing write access to /Users/ce/yaowu/wechaty-getting-started/node_modules/uri-js/node_modules npm ERR! path /Users/ce/yaowu/wechaty-getting-started/node_modules/tough-cookie/node_modules npm ERR! code EACCES npm ERR! errno -13 npm ERR! syscall access npm ERR! Error: EACCES: permission denied, access '/Users/ce/yaowu/wechaty-getting-started/node_modules/tough-cookie/node_modules' npm ERR! { [Error: EACCES: permission denied, access '/Users/ce/yaowu/wechaty-getting-started/node_modules/tough-cookie/node_modules'] npm ERR! stack: npm ERR! 'Error: EACCES: permission denied, access '/Users/ce/yaowu/wechaty-getting-started/node_modules/tough-cookie/node_modules'', npm ERR! errno: -13, npm ERR! code: 'EACCES', npm ERR! syscall: 'access', npm ERR! path: npm ERR! '/Users/ce/yaowu/wechaty-getting-started/node_modules/tough-cookie/node_modules' } npm ERR! npm ERR! The operation was rejected by your operating system. npm ERR! It is likely you do not have the permissions to access this file as the current user npm ERR! npm ERR! If you believe this might be a permissions issue, please double-check the npm ERR! permissions of the file and its containing directories, or try running npm ERR! the command again as root/Administrator (though this is not recommended). I:wechaty-getting-started ce$ sudo npm install puppeteer@1.12.2
puppeteer@1.12.2 install /Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer node install.js
ERROR: Failed to download Chromium r624492! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download.
{ Error: EACCES: permission denied, mkdir '/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/.local-chromium'
-- ASYNC --
at BrowserFetcher. (/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/lib/helper.js:108:27)
at Object. (/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/install.js:64:16)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)
errno: -13,
code: 'EACCES',
syscall: 'mkdir',
path:
'/Users/ce/yaowu/wechaty-getting-started/node_modules/puppeteer/.local-chromium' }
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! puppeteer@1.12.2 install: node install.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the puppeteer@1.12.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in: npm ERR! /Users/ce/.npm/_logs/2019-02-21T02_49_40_445Z-debug.log I:wechaty-getting-started ce$ nvm list v6.11.2 v10.10.0 -> v10.15.0 v11.10.0