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
My previous bug report in #20616 around blitBuffer was fixed, but this surfaced a bug a few lines below the old one (both bugs were surfaced with this testcase that tries to use web-push).
The error is src.subarray is not a function, and can be replicated with the same code sample as in the previous bug report:
➜ val.town git:(v3) ✗ deno
Deno 1.37.1
exit using ctrl+d, ctrl+c, or close()
REPL is running with all permissions allowed.
To specify permissions, run `deno repl` with allow flags.
> import { Buffer } from "node:buffer"
undefined
> Buffer.from('ZmRzYWZkYWZkc2E', 'base64url')
Uncaught TypeError: src.subarray is not a function
at blitBuffer (ext:deno_node/internal/buffer.mjs:1779:15)
at Uint8Array.base64urlWrite (ext:deno_node/internal/buffer.mjs:691:10)
at Object.write (ext:deno_node/internal/buffer.mjs:2195:11)
at Uint8Array.write (ext:deno_node/internal/buffer.mjs:794:14)
at fromString (ext:deno_node/internal/buffer.mjs:214:22)
at _from (ext:deno_node/internal/buffer.mjs:119:12)
at Function.from (ext:deno_node/internal/buffer.mjs:157:10)
at <anonymous>:2:8
As far as I can tell, the blitBuffer method is usually passed an Array as its first argment:
But the subarray method only exists on TypedArray instances. It seems like this file - buffer.mjs - has neither tests nor types. Maybe this could get some test coverage?
The text was updated successfully, but these errors were encountered:
My previous bug report in #20616 around blitBuffer was fixed, but this surfaced a bug a few lines below the old one (both bugs were surfaced with this testcase that tries to use web-push).
The error is src.subarray is not a function, and can be replicated with the same code sample as in the previous bug report:
As far as I can tell, the
blitBuffer
method is usually passed an Array as its first argment:deno/ext/node/polyfills/internal/buffer.mjs
Line 748 in d5b6c63
But the
subarray
method only exists on TypedArray instances. It seems like this file - buffer.mjs - has neither tests nor types. Maybe this could get some test coverage?The text was updated successfully, but these errors were encountered: