Title: quic: reader is lazily allocated in QuicStream, an incoming unidi stream with fin will loose its data · Issue #66347 · nodejs/node · GitHub
Open Graph Title: quic: reader is lazily allocated in QuicStream, an incoming unidi stream with fin will loose its data · Issue #66347 · nodejs/node
X Title: quic: reader is lazily allocated in QuicStream, an incoming unidi stream with fin will loose its data · Issue #66347 · nodejs/node
Description: Again, when working on webtransport support, my test uncovered after rebasing after 3 weeks absence, an issue that data can be lost. (was not there before, can be changes in quic or stream iter). What the test does is, create a server si...
Open Graph Description: Again, when working on webtransport support, my test uncovered after rebasing after 3 weeks absence, an issue that data can be lost. (was not there before, can be changes in quic or stream iter). W...
X Description: Again, when working on webtransport support, my test uncovered after rebasing after 3 weeks absence, an issue that data can be lost. (was not there before, can be changes in quic or stream iter). W...
Opengraph URL: https://github.com/nodejs/node/issues/66347
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"quic: reader is lazily allocated in QuicStream, an incoming unidi stream with fin will loose its data","articleBody":"Again, when working on webtransport support, my test uncovered after rebasing after 3 weeks absence,\nan issue that data can be lost. (was not there before, can be changes in quic or stream iter).\n\nWhat the test does is, create a server side unidirectional stream with some bytes and immediately closing the stream.\nThe client is unable to read the data, because I use:\n```\nthis.readiterator_ = this.stream[Symbol.asyncIterator]()\n```\nand then later call:\n```\n await this.readiterator_.next()\n```\nwhen the code needs it.\n\nThe problem is, that only at the call to `next()` the async iterator of `QuicStream` is called, that creates the reader on the C++ Stream object.\nHowever, the `#handle` is destroyed once the stream is closed (from the server side) and a later call to `this.readiterator_.next()` can not retrieve that data on client side as the `#handle` is gone, and the data was in its accumulation buffer. \n\nI can work around this problem, by calling `next()` early and awaiting the promise later. (at least I hope)\n\nBut I am wondering, if the lazy allocation of the stream's reader is a good idea. I know from user querys about my webtransport package, that a lot of user use streams to send messages and immediately close them (though I do not like this pattern), but this use pattern may result into the same problem.\n\n@pimterry @jasnell \nWhat do you think about this? ","author":{"url":"https://github.com/martenrichter","@type":"Person","name":"martenrichter"},"datePublished":"2026-09-27T12:12:26Z","url":"https://github.com/nodejs/node/issues/66347"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:6bbdacb7-4956-8ee6-94ad-6c1b5ab49cee |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 85C4:12138D:525DDF:6DF62E:6AFBF071 |
| html-safe-nonce | 9f873e1495c68f6d06dbbf1beb4410cdfa3ba5dbf74e6247fcff75d95265a3a7 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NUM0OjEyMTM4RDo1MjVEREY6NkRGNjJFOjZBRkJGMDcxIiwidmlzaXRvcl9pZCI6IjM3MjU4ODMyNDIwMTY2NjU3MTMiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 3b59e9eafe0ffcddbcb18524ef8671ed11e3d6c70805cc59097d8c810ad3f1db |
| hovercard-subject-tag | issue:5602525662 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/66347/issue_layout |
| twitter:image | https://opengraph.githubassets.com/1610073c32d4bd87431bd21a62acb49d5896092ab5a8b49ee3a137fca73718a7/nodejs/node/issues/66347 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/1610073c32d4bd87431bd21a62acb49d5896092ab5a8b49ee3a137fca73718a7/nodejs/node/issues/66347 |
| og:image:alt | Again, when working on webtransport support, my test uncovered after rebasing after 3 weeks absence, an issue that data can be lost. (was not there before, can be changes in quic or stream iter). W... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | martenrichter |
| hostname | github.com |
| expected-hostname | github.com |
| None | fa74413a1d84dac536fcca0740780bcbd3207bafec0e51873b73ff8e8cca032f |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | b3b5633a74535d9c23385512d534c66c8fde1907 |
| ui-target | canary-1 |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width