-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
downloadで途中で切断された場合に正常終了してしまう #1020
Comments
https://tools.ietf.org/html/rfc7230#section-3.4
えー |
↑たぶん特に変な事は書いてないです 1
だったら10バイト受信したら正常終了すればいい 2
だったら応答終了をマークするchunkを受信できたら正常終了すればいい 3
なら接続断を検知したら正常終了とすればいい って意味でほとんどのサーバーは1, 2のいずれかなので問題ないです。 今問題になってるのは、 |
これ |
|
とりあえずこんな感じ? HTTP/1.0を指定する方法はなさそうだった |
Node http で、socket, request, response の error インベントlistenしてもerrorなんて起きなかった。 |
Node http で aborted イベントをListenすればいいみたい でも request も node-fetch も対応してない様子 |
gotがちゃんとしてるみたい |
💡 Summary
みたいな10バイトあるはずが3バイトしか送らないで切断しても
3バイトのファイルをDLして正常終了してしまう。
note-fetchだけではなくrequestのバージョンでも起こる
🙂 Expected Behavior
📝 Steps to Reproduce
📌 Environment
The text was updated successfully, but these errors were encountered: