Fix broken test on linux#2699
Merged
Merged
Conversation
Signed-off-by: Matteo Collina <hello@matteocollina.com>
KhafraDev
approved these changes
Feb 5, 2024
mcollina
commented
Feb 5, 2024
| fetchParams.controller.controller.enqueue(buffer) | ||
| try { | ||
| fetchParams.controller.controller.enqueue(buffer) | ||
| } catch {} |
Member
Author
There was a problem hiding this comment.
@KhafraDev please review this. A wpt is failing without it: https://github.com/nodejs/undici/blob/main/test/wpt/tests/fetch/api/basic/stream-safe-creation.any.js
Uncaught exception in "D:\a\undici\undici\test\wpt\tests\fetch\api\basic\stream-safe-creation.any.js":
TypeError [ERR_INVALID_STATE]: Invalid state: ReadableStream is already closed
at ReadableByteStreamController.enqueue (node:internal/webstreams/readablestream:1160:13)
at fetchParams.controller.resume (D:\a\undici\undici\lib\fetch\index.js:2024:43)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
================================================================================================
Uncaught exception in "D:\a\undici\undici\test\wpt\tests\fetch\api\basic\stream-safe-creation.any.js":
TypeError [ERR_INVALID_STATE]: Invalid state: ReadableStream is already closed
at ReadableByteStreamController.enqueue (node:internal/webstreams/readablestream:1160:13)
at fetchParams.controller.resume (D:\a\undici\undici\lib\fetch\index.js:2024:43)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
================================================================================================
ronag
approved these changes
Feb 5, 2024
Member
Author
|
@KhafraDev please take a look at the changes in fetch(), I'm not 100% convinced but the WPTs and our test pass. |
KhafraDev
reviewed
Feb 5, 2024
KhafraDev
left a comment
Member
There was a problem hiding this comment.
I have 0 time this week to dig into it, but nothing seems off to me.
Contributor
|
I will have a look now |
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.
Fixes #2697