docker version
Client:
Version: 20.10.10
API version: 1.41
Go version: go1.17.2
Git commit: b485636f4b
Built: Tue Oct 26 03:44:01 2021
OS/Arch: linux/amd64
Context: default
Experimental: true
Server:
Engine:
Version: 20.10.10
API version: 1.41 (minimum version 1.12)
Go version: go1.17.2
Git commit: e2f740de44
Built: Tue Oct 26 03:43:48 2021
OS/Arch: linux/amd64
Experimental: false
containerd:
Version: v1.5.7
GitCommit: 8686ededfc90076914c5238eb96c883ea093a8ba.m
runc:
Version: 1.0.2
GitCommit: v1.0.2-0-g52b36a2d
docker-init:
Version: 0.19.0
GitCommit: de40ad0
时间:2021年10月27日 12:42:17 PM
现象:安装wechaty-puppet-wechat过程中失败,npm ERR! GotError [RequestError]: socket hang up
虚拟终端日志:
```bash
[ht@arch ~]$ date
Wed Oct 27 12:42:17 PM CST 2021
[ht@arch ~]$ sudo docker run -d -e AIBOTK_KEY="b603d509ba8ba9cac6c441088f4bee7ed942f383" -e
AIBOTK_SECRET="2b93799e9920bda45e986fb7b29e880ad8cd3d7c" --name=wechatBot aibotk⁄wechat-assistant
[sudo] ht 的密码:
docker: invalid reference format.
See 'docker run --help'.
[ht@arch ~]$ sudo docker run -d -e AIBOTK_KEY="b603d509ba8ba9cac6c441088f4bee7ed942f383" -e
AIBOTK_SECRET="2b93799e9920bda45e986fb7b29e880ad8cd3d7c" --name=wechatBot aibotk/wechat-assistant
docker: Error response from daemon: Conflict. The container name "/wechatBot" is already in use by container
"00afc0fd99502e3acb9065b95c60bba073892458526e0f7eece90519edd5bfb6". You have to remove (or rename) that container to be able to
reuse that name.
See 'docker run --help'.
[ht@arch ~]$ sudo docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
00afc0fd9950 aibotk/wechat-assistant "/wechaty/bin/entryp…" 22 hours ago Exited (137) 20 hours ago wechatBot
[ht@arch ~]$ sudo docker rm 00afc0fd9950
00afc0fd9950
[ht@arch ~]$ sudo docker run -d -e AIBOTK_KEY="b603d509ba8ba9cac6c441088f4bee7ed942f383" -e
AIBOTK_SECRET="2b93799e9920bda45e986fb7b29e880ad8cd3d7c" --name=wechatBot aibotk/wechat-assistant
3b666050b1f47865464c55bcefc51b04f48f33bb25cfde57cf24168fcad3a5d8
[ht@arch ~]$ sudo docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
3b666050b1f4 aibotk/wechat-assistant "/wechaty/bin/entryp…" 4 seconds ago Up 3 seconds wechatBot
[ht@arch ~]$ sudo docker logs -f --tail=200 3b666050b1f4
__ __ _ _
\ \ / /__ ___| |__ __ _| |_ _ _
\ \ /\ / / _ \/ __| '_ \ / _` | __| | | |
\ V V / __/ (__| | | | (_| | |_| |_| |
\_/\_/ \___|\___|_| |_|\__,_|\__|\__, |
|___/
____________________________________________________
https://www.chatie.io
____ _ _
/ ___|___ _ __ _ __ ___ ___| |_(_)_ __ __ _
| | / _ \| '_ \| '_ \ / _ \/ __| __| | '_ \ / _` |
| |__| (_) | | | | | | | __/ (__| |_| | | | | (_| |
\____\___/|_| |_|_| |_|\___|\___|\__|_|_| |_|\__, |
|___/
____ _ _ ____ _
/ ___| |__ __ _| |_| __ ) ___ | |_ ___
| | | '_ \ / _` | __| _ \ / _ \| __/ __|
| |___| | | | (_| | |_| |_) | (_) | |_\__ \
\____|_| |_|\__,_|\__|____/ \___/ \__|___/
WECHATY Environment Variables: 1
WECHATY_DOCKER=1
Starting Docker Container for Wechaty v0.77.3 with Node.js v16.11.1 ...
> wechat-assistant@3.5.9 start
> node index.js
使用环境变量中的 aibotkKey
使用环境变量中的 aibotkSecret
12:43:10 INFO PuppetManager install(wechaty-puppet-wechat@>=0.28) please wait ...
npm: npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm: npm WARN
npm: deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm: npm WARN deprecated
npm: har-validator@5.1.5: this library is no longer supported
npm: npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained
npm: npm WARN deprecated @hapi/formula@1.2.0: Moved to 'npm install @sideway/formula'
npm: npm WARN deprecated @hapi/pinpoint@1.0.2: Moved to 'npm install @sideway/pinpoint'
npm: npm
npm: WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
npm: npm WARN deprecated @hapi/address@2.1.4: Moved to 'npm install @sideway/address'
npm: npm WARN deprecated
npm: uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is
known to be problematic. See https://v8.dev/blog/math-random for details.
npm: npm WARN deprecated
npm: @hapi/joi@16.1.8: Switch to 'npm install joi'
npm: npm WARN
npm: deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm: npm WARN deprecated tslint-config-standard@9.0.0: TSLint is deprecated, please move to ESLint:
https://github.com/blakeembrey/tslint-config-standard/issues/61
npm: npm WARN deprecated babel-eslint@10.1.0: babel-eslint is now @babel/eslint-parser. This package will no longer receive
updates.
npm: npm WARN deprecated
npm: eslint-plugin-standard@5.0.0: standard 16.0.0 and eslint-config-standard 16.0.0 no longer require the eslint-plugin-standard
package. You can remove it from your dependencies with 'npm rm eslint-plugin-standard'. More info here:
https://github.com/standard/standard/issues/1316
npm: npm WARN deprecated
npm: tslint@6.1.3: TSLint has been deprecated in favor of ESLint. Please see https://github.com/palantir/tslint/issues/4534 for
more information.
npm: npm WARN
npm: deprecated @types/dotenv@8.2.0: This is a stub types definition. dotenv provides its own type definitions, so you do not need
this installed.
npm: npm WARN deprecated uuid@3.3.2: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain
circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm: npm
npm: notice
npm notice New minor version of npm available! 8.0.0 -> 8.1.1
npm notice Changelog:
npm notice Run `npm install -g npm@8.1.1` to update!
npm notice
npm: npm ERR!
npm: code 1
npm ERR! path /bot/node_modules/wechaty/node_modules/node-jq
npm: npm
npm: ERR! command failed
npm ERR! command sh -c npm run install-binary
npm ERR! > node-jq@1.12.0 install-binary
npm ERR! > node scripts/install-binary.js
npm ERR!
npm ERR! Downloading jq from https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
npm ERR! GotError [RequestError]: socket hang up
npm ERR! at ClientRequest. (/bot/node_modules/wechaty/node_modules/got/index.js:182:22)
npm ERR! at Object.onceWrapper (node:events:510:26)
npm ERR! at ClientRequest.emit (node:events:390:28)
npm ERR! at TLSSocket.socketOnEnd (node:_http_client:471:9)
npm ERR! at TLSSocket.emit (node:events:402:35)
npm
npm: ERR! at endReadableNT (node:internal/streams/readable:1343:12)
npm ERR! at processTicksAndRejections (node:internal/process/task_queues:83:21) {
npm ERR! code: 'ECONNRESET',
npm ERR! host: 'github.com',
npm ERR!
npm: hostname: 'github.com',
npm ERR! method: 'GET',
npm ERR! path: '/stedolan/jq/releases/download/jq-1.6/jq-linux64',
npm ERR! protocol: 'https:',
npm ERR! url: 'https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64'
npm ERR! }
npm:
npm: npm ERR! A complete log of this run can be found in:
npm ERR! /bot/.npm/_logs/2021-10-27T05_03_23_650Z-debug.log
Error: Command failed: npm install wechaty-puppet-wechat@>=0.28 --no-save
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/formula@1.2.0: Moved to 'npm install @sideway/formula'
npm WARN deprecated @hapi/pinpoint@1.0.2: Moved to 'npm install @sideway/pinpoint'
npm WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/address@2.1.4: Moved to 'npm install @sideway/address'
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain
circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated @hapi/joi@16.1.8: Switch to 'npm install joi'
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated tslint-config-standard@9.0.0: TSLint is deprecated, please move to ESLint:
https://github.com/blakeembrey/tslint-config-standard/issues/61
npm WARN deprecated babel-eslint@10.1.0: babel-eslint is now @babel/eslint-parser. This package will no longer receive updates.
npm WARN deprecated eslint-plugin-standard@5.0.0: standard 16.0.0 and eslint-config-standard 16.0.0 no longer require the eslint-
plugin-standard package. You can remove it from your dependencies with 'npm rm eslint-plugin-standard'. More info here:
https://github.com/standard/standard/issues/1316
npm WARN deprecated tslint@6.1.3: TSLint has been deprecated in favor of ESLint. Please see
https://github.com/palantir/tslint/issues/4534 for more information.
npm WARN deprecated @types/dotenv@8.2.0: This is a stub types definition. dotenv provides its own type definitions, so you do not
need this installed.
npm WARN deprecated uuid@3.3.2: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain
circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm notice
npm notice New minor version of npm available! 8.0.0 -> 8.1.1
npm notice Changelog:
npm notice Run `npm install -g npm@8.1.1` to update!
npm notice
npm ERR! code 1
npm ERR! path /bot/node_modules/wechaty/node_modules/node-jq
npm ERR! command failed
npm ERR! command sh -c npm run install-binary
npm ERR! > node-jq@1.12.0 install-binary
npm ERR! > node scripts/install-binary.js
npm ERR!
npm ERR! Downloading jq from https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
npm ERR! GotError [RequestError]: socket hang up
npm ERR! at ClientRequest. (/bot/node_modules/wechaty/node_modules/got/index.js:182:22)
npm ERR! at Object.onceWrapper (node:events:510:26)
npm ERR! at ClientRequest.emit (node:events:390:28)
npm ERR! at TLSSocket.socketOnEnd (node:_http_client:471:9)
npm ERR! at TLSSocket.emit (node:events:402:35)
npm ERR! at endReadableNT (node:internal/streams/readable:1343:12)
npm ERR! at processTicksAndRejections (node:internal/process/task_queues:83:21) {
npm ERR! code: 'ECONNRESET',
npm ERR! host: 'github.com',
npm ERR! hostname: 'github.com',
npm ERR! method: 'GET',
npm ERR! path: '/stedolan/jq/releases/download/jq-1.6/jq-linux64',
npm ERR! protocol: 'https:',
npm ERR! url: 'https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64'
npm ERR! }
npm ERR! A complete log of this run can be found in:
npm ERR! /bot/.npm/_logs/2021-10-27T05_03_23_650Z-debug.log
at ChildProcess.exithandler (node:child_process:397:12)
at ChildProcess.emit (node:events:390:28)
at ChildProcess.emit (node:domain:475:12)
at maybeClose (node:internal/child_process:1064:16)
at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5) {
killed: false,
code: 1,
signal: null,
cmd: 'npm install wechaty-puppet-wechat@>=0.28 --no-save'
}
13:03:23 ERR Wechaty start() exception: Command failed: npm install wechaty-puppet-wechat@>=0.28 --no-save
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/formula@1.2.0: Moved to 'npm install @sideway/formula'
npm WARN deprecated @hapi/pinpoint@1.0.2: Moved to 'npm install @sideway/pinpoint'
npm WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/address@2.1.4: Moved to 'npm install @sideway/address'
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain
circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated @hapi/joi@16.1.8: Switch to 'npm install joi'
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated tslint-config-standard@9.0.0: TSLint is deprecated, please move to ESLint:
https://github.com/blakeembrey/tslint-config-standard/issues/61
npm WARN deprecated babel-eslint@10.1.0: babel-eslint is now @babel/eslint-parser. This package will no longer receive updates.
npm WARN deprecated eslint-plugin-standard@5.0.0: standard 16.0.0 and eslint-config-standard 16.0.0 no longer require the eslint-
plugin-standard package. You can remove it from your dependencies with 'npm rm eslint-plugin-standard'. More info here:
https://github.com/standard/standard/issues/1316
npm WARN deprecated tslint@6.1.3: TSLint has been deprecated in favor of ESLint. Please see
https://github.com/palantir/tslint/issues/4534 for more information.
npm WARN deprecated @types/dotenv@8.2.0: This is a stub types definition. dotenv provides its own type definitions, so you do not
need this installed.
npm WARN deprecated uuid@3.3.2: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain
circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm notice
npm notice New minor version of npm available! 8.0.0 -> 8.1.1
npm notice Changelog:
npm notice Run `npm install -g npm@8.1.1` to update!
npm notice
npm ERR! code 1
npm ERR! path /bot/node_modules/wechaty/node_modules/node-jq
npm ERR! command failed
npm ERR! command sh -c npm run install-binary
npm ERR! > node-jq@1.12.0 install-binary
npm ERR! > node scripts/install-binary.js
npm ERR!
npm ERR! Downloading jq from https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
npm ERR! GotError [RequestError]: socket hang up
npm ERR! at ClientRequest. (/bot/node_modules/wechaty/node_modules/got/index.js:182:22)
npm ERR! at Object.onceWrapper (node:events:510:26)
npm ERR! at ClientRequest.emit (node:events:390:28)
npm ERR! at TLSSocket.socketOnEnd (node:_http_client:471:9)
npm ERR! at TLSSocket.emit (node:events:402:35)
npm ERR! at endReadableNT (node:internal/streams/readable:1343:12)
npm ERR! at processTicksAndRejections (node:internal/process/task_queues:83:21) {
npm ERR! code: 'ECONNRESET',
npm ERR! host: 'github.com',
npm ERR! hostname: 'github.com',
npm ERR! method: 'GET',
npm ERR! path: '/stedolan/jq/releases/download/jq-1.6/jq-linux64',
npm ERR! protocol: 'https:',
npm ERR! url: 'https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64'
npm ERR! }
npm ERR! A complete log of this run can be found in:
npm ERR! /bot/.npm/_logs/2021-10-27T05_03_23_650Z-debug.log
错误 Error: Command failed: npm install wechaty-puppet-wechat@>=0.28 --no-save
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/formula@1.2.0: Moved to 'npm install @sideway/formula'
npm WARN deprecated @hapi/pinpoint@1.0.2: Moved to 'npm install @sideway/pinpoint'
npm WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/address@2.1.4: Moved to 'npm install @sideway/address'
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain
circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated @hapi/joi@16.1.8: Switch to 'npm install joi'
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated tslint-config-standard@9.0.0: TSLint is deprecated, please move to ESLint:
https://github.com/blakeembrey/tslint-config-standard/issues/61
npm WARN deprecated babel-eslint@10.1.0: babel-eslint is now @babel/eslint-parser. This package will no longer receive updates.
npm WARN deprecated eslint-plugin-standard@5.0.0: standard 16.0.0 and eslint-config-standard 16.0.0 no longer require the eslint-
plugin-standard package. You can remove it from your dependencies with 'npm rm eslint-plugin-standard'. More info here:
https://github.com/standard/standard/issues/1316
npm WARN deprecated tslint@6.1.3: TSLint has been deprecated in favor of ESLint. Please see
https://github.com/palantir/tslint/issues/4534 for more information.
npm WARN deprecated @types/dotenv@8.2.0: This is a stub types definition. dotenv provides its own type definitions, so you do not
need this installed.
npm WARN deprecated uuid@3.3.2: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain
circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm notice
npm notice New minor version of npm available! 8.0.0 -> 8.1.1
npm notice Changelog:
npm notice Run `npm install -g npm@8.1.1` to update!
npm notice
npm ERR! code 1
npm ERR! path /bot/node_modules/wechaty/node_modules/node-jq
npm ERR! command failed
npm ERR! command sh -c npm run install-binary
npm ERR! > node-jq@1.12.0 install-binary
npm ERR! > node scripts/install-binary.js
npm ERR!
npm ERR! Downloading jq from https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
npm ERR! GotError [RequestError]: socket hang up
npm ERR! at ClientRequest. (/bot/node_modules/wechaty/node_modules/got/index.js:182:22)
npm ERR! at Object.onceWrapper (node:events:510:26)
npm ERR! at ClientRequest.emit (node:events:390:28)
npm ERR! at TLSSocket.socketOnEnd (node:_http_client:471:9)
npm ERR! at TLSSocket.emit (node:events:402:35)
npm ERR! at endReadableNT (node:internal/streams/readable:1343:12)
npm ERR! at processTicksAndRejections (node:internal/process/task_queues:83:21) {
npm ERR! code: 'ECONNRESET',
npm ERR! host: 'github.com',
npm ERR! hostname: 'github.com',
npm ERR! method: 'GET',
npm ERR! path: '/stedolan/jq/releases/download/jq-1.6/jq-linux64',
npm ERR! protocol: 'https:',
npm ERR! url: 'https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64'
npm ERR! }
npm ERR! A complete log of this run can be found in:
npm ERR! /bot/.npm/_logs/2021-10-27T05_03_23_650Z-debug.log
at ChildProcess.exithandler (node:child_process:397:12)
at ChildProcess.emit (node:events:390:28)
at ChildProcess.emit (node:domain:475:12)
at maybeClose (node:internal/child_process:1064:16)
at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5) {
killed: false,
code: 1,
signal: null,
cmd: 'npm install wechaty-puppet-wechat@>=0.28 --no-save'
}
13:03:23 WARN Wechaty stop() puppet.stop() exception: Cannot read properties of undefined (reading 'stop')
接口https://api-bot.aibotk.com/open/v1/api/wechat/qrerror请求失败 undefined
推送错误成功 Commandfailed:npminstallwechaty-puppet-wechat@>=0.28--no-savenpmWARNdeprecatedresolve-
url@0.2.1:https://github.com/lydell/resolve-
url#deprecatednpmWARNdeprecatedurix@0.1.0:Pleaseseehttps://github.com/lydell/urix#deprecatednpmWARNdeprecatedhar-
validator@5.1.5:thislibraryisnolongersupportednpmWARNdeprecated@hapi/topo@3.1.6:Thisversionhasbeendeprecatedandisnolongersupported
ormaintainednpmWARNdeprecated@hapi/formula@1.2.0:Movedto'npminstall@sideway/formula'npmWARNdeprecated@hapi/pinpoint@1.0.2:Movedto'
npminstall@sideway/pinpoint'npmWARNdeprecated@hapi/hoek@8.5.1:ThisversionhasbeendeprecatedandisnolongersupportedormaintainednpmWAR
Ndeprecated@hapi/address@2.1.4:Movedto'npminstall@sideway/address'npmWARNdeprecateduuid@3.4.0:Pleaseupgradetoversion7orhigher.Olde
rversionsmayuseMath.random()incertaincircumstances,whichisknowntobeproblematic.Seehttps://v8.dev/blog/math-
randomfordetails.npmWARNdeprecated@hapi/joi@16.1.8:Switchto'npminstalljoi'npmWARNdeprecatedrequest@2.88.2:requesthasbeendeprecated
,seehttps://github.com/request/request/issues/3142npmWARNdeprecatedtslint-config-
standard@9.0.0:TSLintisdeprecated,pleasemovetoESLint:https://github.com/blakeembrey/tslint-config-
standard/issues/61npmWARNdeprecatedbabel-eslint@10.1.0:babel-eslintisnow@babel/eslint-
parser.Thispackagewillnolongerreceiveupdates.npmWARNdeprecatedeslint-plugin-standard@5.0.0:standard16.0.0andeslint-config-
standard16.0.0nolongerrequiretheeslint-plugin-standardpackage.Youcanremoveitfromyourdependencieswith'npmrmeslint-plugin-
standard'.Moreinfohere:https://github.com/standard/standard/issues/1316npmWARNdeprecatedtslint@6.1.3:TSLinthasbeendeprecatedinfavo
rofESLint.Pleaseseehttps://github.com/palantir/tslint/issues/4534formoreinformation.npmWARNdeprecated@types/dotenv@8.2.0:Thisisast
ubtypesdefinition.dotenvprovidesitsowntypedefinitions,soyoudonotneedthisinstalled.npmWARNdeprecateduuid@3.3.2:Pleaseupgradetoversi
on7orhigher.OlderversionsmayuseMath.random()incertaincircumstances,whichisknowntobeproblematic.Seehttps://v8.dev/blog/math-
randomfordetails.npmnoticenpmnoticeNewminorversionofnpmavailable!8.0.0-
>8.1.1npmnoticeChangelog:npmnoticeRun`npminstall-gnpm@8.1.1`toupdate!
npmnoticenpmERR!code1npmERR!path/bot/node_modules/wechaty/node_modules/node-jqnpmERR!commandfailednpmERR!commandsh-
cnpmruninstall-binarynpmERR!>node-jq@1.12.0install-binarynpmERR!>nodescripts/install-binary.jsnpmERR!npmERR!
Downloadingjqfromhttps://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64npmERR!GotError
[RequestError]:sockethangupnpmERR!atClientRequest.(/bot/node_modules/wechaty/node_modules/got/index.js:182:22)npmERR!
atObject.onceWrapper(node:events:510:26)npmERR!atClientRequest.emit(node:events:390:28)npmERR!atTLSSocket.socketOnEnd
(node:_http_client:471:9)npmERR!atTLSSocket.emit(node:events:402:35)npmERR!atendReadableNT
(node:internal/streams/readable:1343:12)npmERR!atprocessTicksAndRejections(node:internal/process/task_queues:83:21){npmERR!
code:'ECONNRESET',npmERR!host:'github.com',npmERR!hostname:'github.com',npmERR!method:'GET',npmERR!
path:'/stedolan/jq/releases/download/jq-1.6/jq-linux64',npmERR!protocol:'https:',npmERR!
url:'https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64'npmERR!}npmERR!
Acompletelogofthisruncanbefoundin:npmERR!/bot/.npm/_logs/2021-10-27T05_03_23_650Z-debug.log
npm notice
npm notice New minor version of npm available! 8.0.0 -> 8.1.1
npm notice Changelog:
npm notice Run `npm install -g npm@8.1.1` to update!
npm notice
__ __ _ _
\ \ / /__ ___| |__ __ _| |_ _ _
\ \ /\ / / _ \/ __| '_ \ / _` | __| | | |
\ V V / __/ (__| | | | (_| | |_| |_| |
\_/\_/ \___|\___|_| |_|\__,_|\__|\__, |
|___/
____________________________________________________
https://www.chatie.io
_____ _ _ ___
| ____|_ _(_) |_ / _ \
| _| \ \/ / | __| | | | |
| |___ > <| | |_ | |_| |
|_____/_/\_\_|\__| \___/
[ht@arch ~]$
```
操作系统是ArchLinux,内核版本:5.14.14-arch1-1(64-位) 虚拟终端用的是konsole
docker version
Client: Version: 20.10.10 API version: 1.41 Go version: go1.17.2 Git commit: b485636f4b Built: Tue Oct 26 03:44:01 2021 OS/Arch: linux/amd64 Context: default Experimental: true Server: Engine: Version: 20.10.10 API version: 1.41 (minimum version 1.12) Go version: go1.17.2 Git commit: e2f740de44 Built: Tue Oct 26 03:43:48 2021 OS/Arch: linux/amd64 Experimental: false containerd: Version: v1.5.7 GitCommit: 8686ededfc90076914c5238eb96c883ea093a8ba.m runc: Version: 1.0.2 GitCommit: v1.0.2-0-g52b36a2d docker-init: Version: 0.19.0 GitCommit: de40ad0时间:2021年10月27日 12:42:17 PM
现象:安装wechaty-puppet-wechat过程中失败,npm ERR! GotError [RequestError]: socket hang up
虚拟终端日志:
```bash [ht@arch ~]$ date Wed Oct 27 12:42:17 PM CST 2021 [ht@arch ~]$ sudo docker run -d -e AIBOTK_KEY="b603d509ba8ba9cac6c441088f4bee7ed942f383" -e AIBOTK_SECRET="2b93799e9920bda45e986fb7b29e880ad8cd3d7c" --name=wechatBot aibotk⁄wechat-assistant [sudo] ht 的密码: docker: invalid reference format. See 'docker run --help'. [ht@arch ~]$ sudo docker run -d -e AIBOTK_KEY="b603d509ba8ba9cac6c441088f4bee7ed942f383" -e AIBOTK_SECRET="2b93799e9920bda45e986fb7b29e880ad8cd3d7c" --name=wechatBot aibotk/wechat-assistant docker: Error response from daemon: Conflict. The container name "/wechatBot" is already in use by container "00afc0fd99502e3acb9065b95c60bba073892458526e0f7eece90519edd5bfb6". You have to remove (or rename) that container to be able to reuse that name. See 'docker run --help'. [ht@arch ~]$ sudo docker ps -a CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 00afc0fd9950 aibotk/wechat-assistant "/wechaty/bin/entryp…" 22 hours ago Exited (137) 20 hours ago wechatBot [ht@arch ~]$ sudo docker rm 00afc0fd9950 00afc0fd9950 [ht@arch ~]$ sudo docker run -d -e AIBOTK_KEY="b603d509ba8ba9cac6c441088f4bee7ed942f383" -e AIBOTK_SECRET="2b93799e9920bda45e986fb7b29e880ad8cd3d7c" --name=wechatBot aibotk/wechat-assistant 3b666050b1f47865464c55bcefc51b04f48f33bb25cfde57cf24168fcad3a5d8 [ht@arch ~]$ sudo docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 3b666050b1f4 aibotk/wechat-assistant "/wechaty/bin/entryp…" 4 seconds ago Up 3 seconds wechatBot [ht@arch ~]$ sudo docker logs -f --tail=200 3b666050b1f4 __ __ _ _ \ \ / /__ ___| |__ __ _| |_ _ _ \ \ /\ / / _ \/ __| '_ \ / _` | __| | | | \ V V / __/ (__| | | | (_| | |_| |_| | \_/\_/ \___|\___|_| |_|\__,_|\__|\__, | |___/ ____________________________________________________ https://www.chatie.io ____ _ _ / ___|___ _ __ _ __ ___ ___| |_(_)_ __ __ _ | | / _ \| '_ \| '_ \ / _ \/ __| __| | '_ \ / _` | | |__| (_) | | | | | | | __/ (__| |_| | | | | (_| | \____\___/|_| |_|_| |_|\___|\___|\__|_|_| |_|\__, | |___/ ____ _ _ ____ _ / ___| |__ __ _| |_| __ ) ___ | |_ ___ | | | '_ \ / _` | __| _ \ / _ \| __/ __| | |___| | | | (_| | |_| |_) | (_) | |_\__ \ \____|_| |_|\__,_|\__|____/ \___/ \__|___/ WECHATY Environment Variables: 1 WECHATY_DOCKER=1 Starting Docker Container for Wechaty v0.77.3 with Node.js v16.11.1 ... > wechat-assistant@3.5.9 start > node index.js 使用环境变量中的 aibotkKey 使用环境变量中的 aibotkSecret 12:43:10 INFO PuppetManager install(wechaty-puppet-wechat@>=0.28) please wait ... npm: npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated npm: npm WARN npm: deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated npm: npm WARN deprecated npm: har-validator@5.1.5: this library is no longer supported npm: npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained npm: npm WARN deprecated @hapi/formula@1.2.0: Moved to 'npm install @sideway/formula' npm: npm WARN deprecated @hapi/pinpoint@1.0.2: Moved to 'npm install @sideway/pinpoint' npm: npm npm: WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained npm: npm WARN deprecated @hapi/address@2.1.4: Moved to 'npm install @sideway/address' npm: npm WARN deprecated npm: uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. npm: npm WARN deprecated npm: @hapi/joi@16.1.8: Switch to 'npm install joi' npm: npm WARN npm: deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142 npm: npm WARN deprecated tslint-config-standard@9.0.0: TSLint is deprecated, please move to ESLint: https://github.com/blakeembrey/tslint-config-standard/issues/61 npm: npm WARN deprecated babel-eslint@10.1.0: babel-eslint is now @babel/eslint-parser. This package will no longer receive updates. npm: npm WARN deprecated npm: eslint-plugin-standard@5.0.0: standard 16.0.0 and eslint-config-standard 16.0.0 no longer require the eslint-plugin-standard package. You can remove it from your dependencies with 'npm rm eslint-plugin-standard'. More info here: https://github.com/standard/standard/issues/1316 npm: npm WARN deprecated npm: tslint@6.1.3: TSLint has been deprecated in favor of ESLint. Please see https://github.com/palantir/tslint/issues/4534 for more information. npm: npm WARN npm: deprecated @types/dotenv@8.2.0: This is a stub types definition. dotenv provides its own type definitions, so you do not need this installed. npm: npm WARN deprecated uuid@3.3.2: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. npm: npm npm: notice npm notice New minor version of npm available! 8.0.0 -> 8.1.1 npm notice Changelog: