NeteaseCloudMusicApi
NeteaseCloudMusicApi copied to clipboard
只能访问index主页,请求其他功能状态码502报错
环境
-
系统/平台: Windows 11 21H2
-
nodejs 版本: <v16.17.1>
-
API版本: <4.8.2>
出现问题
node app.js运行正常,能正常显示页面,请求搜索等就会报错 [ERR] /search?keywords=海阔天空 { status: 502, body: { code: 502, msg: Error: read ECONNRESET at TLSWrap.onStreamRead (node:internal/stream_base_commons:217:20) { errno: -4077, code: 'ECONNRESET', syscall: 'read', config: [Object], request: [Writable], response: undefined, isAxiosError: true, toJSON: [Function: toJSON] } } } E:\Reptile\Music\NeteaseCloudMusicApi-master\node_modules\express\lib\response.js:1123 : JSON.stringify(value); ^
TypeError: Converting circular structure to JSON
--> starting at object with constructor 'Object'
| property 'httpsAgent' -> object with constructor 'Agent'
| property 'sockets' -> object with constructor 'Object'
| ...
| property 'errored' -> object with constructor 'Object'
--- property 'config' closes the circle
at JSON.stringify (
重现步骤
期待效果
功能能够正常运行
I had a friend that encountered the same thing. Hopefully this helps you.
Go to C:\Windows\System32\drivers\etc
Open hosts
Delete any lines with music.163 or similar
Save (may require Administrator)
Try running CloudApi again.
我也是兄弟,你解决了吗
我也是兄弟,你解决了吗
配hosts换一个music.163.com试试, 我遇到的是海外的服务器dns也会返回海外的cdn地址,访问的时候会报502,换成国内的ip就好了