Title: readable event,outputs are different between v9.11 and v10.14.2 · Issue #25158 · nodejs/node · GitHub
Open Graph Title: readable event,outputs are different between v9.11 and v10.14.2 · Issue #25158 · nodejs/node
X Title: readable event,outputs are different between v9.11 and v10.14.2 · Issue #25158 · nodejs/node
Description: 1.txt 内容为123456789, 代码: const rs = fs.createReadStream(path.join(__dirname, './1.txt'), { highWaterMark: 3, encoding: 'utf8' }) rs.on('readable', () => { let ch = rs.read(1) console.log('ch', ch); }) 9.11版本node 输出 ch 1(readable触发了1次) 10....
Open Graph Description: 1.txt 内容为123456789, 代码: const rs = fs.createReadStream(path.join(__dirname, './1.txt'), { highWaterMark: 3, encoding: 'utf8' }) rs.on('readable', () => { let ch = rs.read(1) console.log('ch', ch); ...
X Description: 1.txt 内容为123456789, 代码: const rs = fs.createReadStream(path.join(__dirname, './1.txt'), { highWaterMark: 3, encoding: 'utf8' }) rs.on('readable', () => { let ch = rs.read...
Opengraph URL: https://github.com/nodejs/node/issues/25158
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":" readable event,outputs are different between v9.11 and v10.14.2","articleBody":"1.txt 内容为123456789,\r\n代码:\r\nconst rs = fs.createReadStream(path.join(__dirname, './1.txt'), {\r\n highWaterMark: 3,\r\n encoding: 'utf8'\r\n})\r\nrs.on('readable', () => {\r\n let ch = rs.read(1)\r\n console.log('ch', ch);\r\n})\r\n9.11版本node 输出 ch 1(readable触发了1次)\r\n10.14.2版本 输出 ch 1 ch 2 (readable触发了2次)\r\n不太懂 readable 什么情况下会再次触发, ","author":{"url":"https://github.com/curry-wxj","@type":"Person","name":"curry-wxj"},"datePublished":"2018-12-21T02:24:17Z","url":"https://github.com/nodejs/node/issues/25158"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| 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:066670af-586f-05e4-cc2e-7cee27e40fb9 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 93CE:357BF:13F7A6:1AF6BD:6AED372D |
| html-safe-nonce | 0776dcae96f6b997549a223ec687308777b14ba9b74a89f22057300194c9ec90 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5M0NFOjM1N0JGOjEzRjdBNjoxQUY2QkQ6NkFFRDM3MkQiLCJ2aXNpdG9yX2lkIjoiNjIwMzQyODAyNzEzMjM2MDQ5MyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 1d777d15b3088395506656e605954c026509c66cf90c754a6f33837b0b313725 |
| hovercard-subject-tag | issue:393287610 |
| 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/25158/issue_layout |
| twitter:image | https://opengraph.githubassets.com/8992d53b78ca8885deb6a50ec533cfa30213735aad4ce7c5559295ab084a10e0/nodejs/node/issues/25158 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/8992d53b78ca8885deb6a50ec533cfa30213735aad4ce7c5559295ab084a10e0/nodejs/node/issues/25158 |
| og:image:alt | 1.txt 内容为123456789, 代码: const rs = fs.createReadStream(path.join(__dirname, './1.txt'), { highWaterMark: 3, encoding: 'utf8' }) rs.on('readable', () => { let ch = rs.read(1) console.log('ch', ch); ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | curry-wxj |
| hostname | github.com |
| expected-hostname | github.com |
| None | 26c92a9388ddfad3fa88d132b5d5f0b4747030233dcc4e5efb05f1cbae152184 |
| 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 | c629ad99c254d306375fc8354d04321c2c362236 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width