FetchError: request to http://api.weixin.qq.com/_/cos/getauth failed, reason: socket hang up
at ClientRequest.<anonymous> (file:///app/node_modules/node-fetch/src/index.js:108:11)
at ClientRequest.emit (node:events:519:28)
at Socket.socketOnEnd (node:_http_client:524:9)
at Socket.emit (node:events:531:35)
at endReadableNT (node:internal/streams/readable:1696:12)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
type: 'system',
errno: 'ECONNRESET',
code: 'ECONNRESET',
erroredSysCall: undefined
}
环境是微信云开发,配置了本地vscode 的 weixin cloudbase containers的vpc 开发语言是nodejs。
目的是为了在本地访问http://api.weixin.qq.com/_/cos/getauth 这个接口
但目前出现报错的i情况不知道是哪个环节没有调通还是理解上都出了问题。
这个是docker上关于这个vpc服务的内容。
或者说有其他方式可以直接访问腾讯云对象储存实现服务端上传
已经解决了。默认端口和某些梯子冲突。需要全部修改好后重启才能有用。