代码未做任何修改,重新运行后就报下面的错误:
egg-bin dev
2018-05-22 19:23:41,824 INFO 1844 [master] node version v8.11.0
2018-05-22 19:23:41,825 INFO 1844 [master] alinode version v3.11.0
2018-05-22 19:23:41,826 INFO 1844 [master] @ali/begg version 3.6.2
2018-05-22 19:23:42,339 INFO 1844 [master] agent_worker#1:1845 started (511ms)
2018-05-22 19:23:43,451 INFO 1844 [master] @ali/begg started on http://127.0.0.1:7001 (1625ms)
2018-05-22 19:24:27,593 ERROR 1846 A client (::ffff:127.0.0.1:50211) error [HPE_INVALID_METHOD] occurred: Parse Error
2018-05-22 19:24:27,595 ERROR 1846 A client (::ffff:127.0.0.1:50211) error [HPE_INVALID_METHOD] occurred: Parse Error
Translation of this issue:
The code did not make any changes. After rerunning, it reported the following error:
egg-bin dev
2018-05-22 19:23:41,824 INFO 1844 [master] node version v8.11.0
2018-05-22 19:23:41,825 INFO 1844 [master] alinode version v3.11.0
2018-05-22 19:23:41,826 INFO 1844 [master] @ali/begg version 3.6.2
2018-05-22 19:23:42,339 INFO 1844 [master] agent_worker#1:1845 started (511ms)
2018-05-22 19:23:43,451 INFO 1844 [master] @ali/begg started on http://127.0.0.1:7001 (1625ms)
2018-05-22 19:24:27,593 ERROR 1846 A client (::ffff:127.0.0.1:50211) error [HPE_INVALID_METHOD] occurred: Parse Error
2018-05-22 19:24:27,595 ERROR 1846 A client (::ffff:127.0.0.1:50211) error [HPE_INVALID_METHOD] occurred: Parse Error
https://github.com/nodejs/node/issues/19914
收到了一些错误的请求包,你本地有什么扫描工具还是啥的?
没有开任何扫描工具,访问本地网址就会一直报错
用 egg-init --type=simple 初始化个最小可复现仓库,然后提交到你的 GitHub 吧
https://eggjs.org/api/Config.html#onClientError
根据文档你写一个配置,里面输出 err. rawPacket 看看。
同样遇到了这个错误,因为用mkcert给本地装了https证书,然后通过https://localhost:7001 访问就会出现这个错误。
本地有安全扫描,日志文件疯长,怎么解决?
@gx761
hey, please retry after reinstall dependencies and please never lock it.
$ # reinstall deps and never lock it.
$ rm -rf node_modules yarn.lock package-lock.json
$ npm i --no-package-lock
@Julyyq 您好 我也是因为发起https请求出现的这个错误, 请问该怎么解决呢
我也出现过这个问题,如果egg本身配置的是http协议的服务,那么强制使用https协议请求服务,egg后端就会报这个错。
删除整个 node_modules,重新安装下依赖,不要锁版本,应该就没了。
@atian25 为啥不能锁版本?
@atian25 为啥不能锁版本?
https://zhuanlan.zhihu.com/p/22934066
我们每个大版本下只维护一个版本,并保证严格遵循 semver 规则。
如果锁了版本,那你们就要自己承担更新和排查的责任。
我也出现过这个问题,如果egg本身配置的是http协议的服务,那么强制使用https协议请求服务,egg后端就会报这个错。
怎么设置成 https 解决这个问题。这个问题没出解决方案吗。
Most helpful comment
同样遇到了这个错误,因为用mkcert给本地装了https证书,然后通过https://localhost:7001 访问就会出现这个错误。