You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ok I found this previous issue that challenges the same thing and where it was deemed to be correct behaviour. #41159
Interesting then what does the fetch spec intend to happen when you abort a request who's response stream is being read. The current behaviour of a promise hanging forever can hardly be the desired behaviour, but maybe there's some issue in undicis implementation of reading the body? Or I would expect it should hold the lock until it's done reading.
Version
v23.9.0
Platform
Subsystem
No response
What steps will reproduce the bug?
Reading from the body stream of an aborted fetch request will sometimes just hang due to readable stream throwing on cancel.
How often does it reproduce? Is there a required condition?
We've only managed to reproduce it in a docker container with resource constrained cpu.
What is the expected behavior? Why is that the expected behavior?
Canceling a locked readable stream shouldn't throw. Relevant spec. https://streams.spec.whatwg.org/#readable-stream-close
What do you see instead?
Canceling a stream throws if the stream is locked.
Additional information
Here is where the an error is thrown if the stream is locked. Which isn't mentioned in the relevant spec.
This is believed to be the source of the following bug in undici nodejs/undici#4232
The text was updated successfully, but these errors were encountered: