Skip to content

Conversation

@wafuwafu13
Copy link
Contributor

part of: #911

@wafuwafu13
Copy link
Contributor Author

[memo]
https://github.com/denoland/deno_std/actions/runs/3112024713/jobs/5044988623

./node/_fs/_fs_read_test.ts (uncaught error) error: TypeError: The "position" argument must be of type bigint or integer. Received null throw new ERR_INVALID_ARG_TYPE("position", ["integer", "bigint"], position); ^ at __node_internal_ (file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_util.ts:23:11) at read (file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_read.ts:98:3) at file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_read_test.ts:33:7 at file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_open.ts:83:17 This error was not caught from a test and caused the test runner to fail on the referenced module. It most likely originated from a dangling promise, event/timeout handler or top-level code. ./node/_fs/_fs_streams_test.ts (uncaught error) error: TypeError: The "position" argument must be of type bigint or integer. Received null throw new ERR_INVALID_ARG_TYPE("position", ["integer", "bigint"], position); ^ at __node_internal_ (file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_util.ts:23:11) at Object.read (file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_read.ts:98:3) at <computed> (file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_streams.ts:254:8) at new Promise (<anonymous>) at ReadStream._read (file:///home/runner/work/deno_std/deno_std/node/_fs/_fs_streams.ts:252:9) at ReadStream.w.read (file:///home/runner/work/deno_std/deno_std/node/_stream.mjs:10:34273) at Ql (file:///home/runner/work/deno_std/deno_std/node/_stream.mjs:10:35586) at processTicksAndRejections (file:///home/runner/work/deno_std/deno_std/node/_next_tick.ts:41:15) This error was not caught from a test and caused the test runner to fail on the referenced module. It most likely originated from a dangling promise, event/timeout handler or top-level code. FAILURES ./node/_fs/_fs_read_test.ts (uncaught error) ./node/_fs/_fs_streams_test.ts (uncaught error)
@wafuwafu13 wafuwafu13 marked this pull request as draft September 23, 2022 11:08
@wafuwafu13 wafuwafu13 marked this pull request as ready for review September 23, 2022 13:08
cb = optOrBufferOrCb;
} else {
offset = offsetOrCallback as number;
if (Number.isNaN(offset)) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this check be:

validateInteger(offset, 'offset', 0);
@wafuwafu13 wafuwafu13 marked this pull request as draft September 24, 2022 13:20
@wafuwafu13 wafuwafu13 marked this pull request as ready for review September 25, 2022 09:14
@wafuwafu13 wafuwafu13 requested review from cjihrig and removed request for bartlomieju and kt3k September 25, 2022 09:17
Copy link
Contributor

@cjihrig cjihrig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@cjihrig cjihrig merged commit 6913e73 into denoland:main Sep 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants