Conversation
Member
|
I looked the code and it does fix the problem, but it also leaves few other corner cases open and this PR creates a regression when timeout is not defined. ┌─────┬─────────────────────────────────────────┬─────────────────────────┬────────────────────────┬─────────────────────┐
│ # │ Scenario │ main │ PR │ Proposal │
├─────┼─────────────────────────────────────────┼─────────────────────────┼────────────────────────┼─────────────────────┤
│ │ Promise, server waits 3s before │ ❌ waitForEvent: │ │ │
│ A │ responding, download_timeout=10s │ Timeout 1000ms (the │ ✅ │ ✅ │
│ │ │ issue) │ │ │
├─────┼─────────────────────────────────────────┼─────────────────────────┼────────────────────────┼─────────────────────┤
│ B │ Promise, headers at once, body streams │ ✅ │ ✅ │ ✅ │
│ │ for 3s, download_timeout=10s │ │ │ │
├─────┼─────────────────────────────────────────┼─────────────────────────┼────────────────────────┼─────────────────────┤
│ C │ Download keyword, 3s body, │ 💥 Node process crashes │ ✅ │ ✅ │
│ │ download_timeout=10s │ │ │ │
├─────┼─────────────────────────────────────────┼─────────────────────────┼────────────────────────┼─────────────────────┤
│ D │ Promise, 3s body, │ ✅ │ ✅ │ ✅ │
│ │ download_timeout=1.5s, should fail │ │ │ │
├─────┼─────────────────────────────────────────┼─────────────────────────┼────────────────────────┼─────────────────────┤
│ │ Promise with no download_timeout, no │ │ ❌ hangs forever │ │
│ E │ download ever happens, should fail │ ✅ fails after 1s │ (stopped by a 20s test │ ✅ fails after 1s │
│ │ │ │ timeout) │ │
├─────┼─────────────────────────────────────────┼─────────────────────────┼────────────────────────┼─────────────────────┤
│ F │ Download, 3s body, download_timeout=1s, │ 💥 crash │ 💥 still crashes │ ✅ │
│ │ should fail cleanly │ │ │ │
├─────┼─────────────────────────────────────────┼─────────────────────────┼────────────────────────┼─────────────────────┤
│ │ │ │ │ ✅ fails cleanly at │
│ H │ Download, 3s body, no download_timeout │ 💥 crash │ ✅ │ the browser │
│ │ │ │ │ timeout │
└─────┴─────────────────────────────────────────┴─────────────────────────┴────────────────────────┴─────────────────────┘Therefore I made a another fix in #5252 therefore I am going to close this PR. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.