Title: TextEncoder.encodeInto NOT work on BIG utf8 subarray ON 22.4.1 · Issue #62610 · nodejs/node · GitHub
Open Graph Title: TextEncoder.encodeInto NOT work on BIG utf8 subarray ON 22.4.1 · Issue #62610 · nodejs/node
X Title: TextEncoder.encodeInto NOT work on BIG utf8 subarray ON 22.4.1 · Issue #62610 · nodejs/node
Description: Version Welcome to Node.js v22.4.1 Platform Linux dev 6.8.0-88-generic #89-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 11 01:02:46 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux Subsystem No response What steps will reproduce the bug? ` const _TE = new ...
Open Graph Description: Version Welcome to Node.js v22.4.1 Platform Linux dev 6.8.0-88-generic #89-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 11 01:02:46 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux Subsystem No response What steps wi...
X Description: Version Welcome to Node.js v22.4.1 Platform Linux dev 6.8.0-88-generic #89-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 11 01:02:46 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux Subsystem No response What steps wi...
Opengraph URL: https://github.com/nodejs/node/issues/62610
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"TextEncoder.encodeInto NOT work on BIG utf8 subarray ON 22.4.1","articleBody":"### Version\n\nWelcome to Node.js v22.4.1\n\n### Platform\n\n```text\nLinux dev 6.8.0-88-generic #89-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 11 01:02:46 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux\n```\n\n### Subsystem\n\n_No response_\n\n### What steps will reproduce the bug?\n\n`\nconst _TE = new TextEncoder();\nvar s = \"aÿ我𝑒\"\nvar u8a = new Uint8Array(2429682061);\nvar offset = 38928786 ;\n_TE.encodeInto(s,u8a.subarray(offset)) // { read: 0, written: 0 } failed\n_TE.encodeInto(s,u8a.subarray(offset,offset+10)) //{ read: 5, written: 10 } success\n\n\nWelcome to Node.js v22.4.1.\nType \".help\" for more information.\n\u003e const _TE = new TextEncoder();\nundefined\n\u003e var s = \"aÿ我𝑒\"\nundefined\n\u003e var u8a = new Uint8Array(2429682061);\nundefined\n\u003e var offset = 38928786 ;\nundefined\n\u003e _TE.encodeInto(s,u8a.subarray(offset)) // { read: 0, written: 0 } failed\n{ read: 0, written: 0 }\n\u003e _TE.encodeInto(s,u8a.subarray(offset,offset+10)) //{ read: 5, written: 10 } success\n{ read: 5, written: 10 }\n\u003e \n\u003e \n\t\t\t\nWelcome to Node.js v24.14.0.\nType \".help\" for more information.\n\u003e const _TE = new TextEncoder();\nundefined\n\u003e var s = \"aÿ我𝑒\"\nundefined\n\u003e var u8a = new Uint8Array(2429682061);\nundefined\n\u003e var offset = 38928786 ;\nundefined\n\u003e _TE.encodeInto(s,u8a.subarray(offset)) // { read: 0, written: 0 } success\n{ read: 5, written: 10 }\n\u003e _TE.encodeInto(s,u8a.subarray(offset,offset+10)) //{ read: 5, written: 10 } success\n{ read: 5, written: 10 }\n\u003e \n\u003e \t\t\t\n\n`\n\n### How often does it reproduce? Is there a required condition?\n\nalaways in 22.4.1\n\n### What is the expected behavior? Why is that the expected behavior?\n\nsame as 24.14.0\n\n### What do you see instead?\n\nconst _TE = new TextEncoder();\nvar s = \"aÿ我𝑒\"\nvar u8a = new Uint8Array(2429682061);\nvar offset = 38928786 ;\n_TE.encodeInto(s,u8a.subarray(offset)) // 【{ read: 0, written: 0 } failed】\n_TE.encodeInto(s,u8a.subarray(offset,offset+10)) //{ read: 5, written: 10 } success\n\n\n### Additional information\n\n_No response_","author":{"url":"https://github.com/navegador5","@type":"Person","name":"navegador5"},"datePublished":"2026-04-06T03:51:58.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":2},"url":"https://github.com/62610/node/issues/62610"}
| 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:36eb2653-7ab6-612c-bd2e-7ccb4f02cb47 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EADE:39C8F0:74EE87:9DA092:6A4C81D0 |
| html-safe-nonce | b18e34a6cbc0a66e1ac0d007f7ddf4645485c6ab28652ac7154f0468019cfe94 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQURFOjM5QzhGMDo3NEVFODc6OURBMDkyOjZBNEM4MUQwIiwidmlzaXRvcl9pZCI6IjE0OTAzMDAzNzQ0MjYwOTE5ODQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | b56fab24499a74c5f75b6a2cb927608bdd79a5883c6a515ddbf451d39c8fa66a |
| hovercard-subject-tag | issue:4209419497 |
| 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/62610/issue_layout |
| twitter:image | https://opengraph.githubassets.com/cd76dbdc63069df85a4d90d14f1c4b0f5e7f50744fe4b98037039a39aeae33af/nodejs/node/issues/62610 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/cd76dbdc63069df85a4d90d14f1c4b0f5e7f50744fe4b98037039a39aeae33af/nodejs/node/issues/62610 |
| og:image:alt | Version Welcome to Node.js v22.4.1 Platform Linux dev 6.8.0-88-generic #89-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 11 01:02:46 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux Subsystem No response What steps wi... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | navegador5 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 3d11bb817438277de2a940854450e83a7d32b6aeb5014e9e6b00a6423900251c |
| 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 | cd470457e909b9d062f8002cf438ba870e6acff6 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width