Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flaky: test-fs-readfile-tostring-fail #51133

Open
mhdawson opened this issue Dec 12, 2023 · 2 comments
Open

flaky: test-fs-readfile-tostring-fail #51133

mhdawson opened this issue Dec 12, 2023 · 2 comments
Labels
flaky-test Issues and PRs related to the tests with unstable failures on the CI. macos Issues and PRs related to the macOS platform / OSX.

Comments

@mhdawson
Copy link
Member

Test

test-fs-readfile-tostring-fail

Platform

macOS x64

Console output

Error Message
fail (7)
Stacktrace
---
duration_ms: 156.304
exitcode: 7
severity: fail
...

Build links

Additional information

No response

@mhdawson mhdawson added the flaky-test Issues and PRs related to the tests with unstable failures on the CI. label Dec 12, 2023
@github-actions github-actions bot added the macos Issues and PRs related to the macOS platform / OSX. label Dec 12, 2023
@richardlau
Copy link
Member

FWIW this is an out of disk space issue:

06:42:28 not ok 3678 pummel/test-fs-readfile-tostring-fail
06:42:28   ---
06:42:28   duration_ms: 156.30400
06:42:28   severity: fail
06:42:28   exitcode: 7
06:42:28   stack: |-
06:42:28     /Users/iojs/build/workspace/node-test-commit-osx/nodes/osx11-x64/test/pummel/test-fs-readfile-tostring-fail.js:76
06:42:28       throw err;
06:42:28       ^
06:42:28     
06:42:28     AssertionError [ERR_ASSERTION]: ifError got unwanted exception: ENOSPC: no space left on device, write
06:42:28         at Object.callback (/Users/iojs/build/workspace/node-test-commit-osx/nodes/osx11-x64/test/pummel/test-fs-readfile-tostring-fail.js:34:37)
06:42:28         at callback (node:internal/streams/writable:757:21)
06:42:28         at onwriteError (node:internal/streams/writable:597:3)
06:42:28         at onwrite (node:internal/streams/writable:640:7)
06:42:28         at node:internal/fs/streams:513:5
06:42:28         at node:internal/fs/streams:455:14
06:42:28         at FSReqCallback.wrapper [as oncomplete] (node:fs:951:5) {
06:42:28       generatedMessage: false,
06:42:28       code: 'ERR_ASSERTION',
06:42:28       actual: [Error: ENOSPC: no space left on device, write] {
06:42:28         errno: -28,
06:42:28         code: 'ENOSPC',
06:42:28         syscall: 'write'
06:42:28       },
06:42:28       expected: null,
06:42:28       operator: 'ifError'
06:42:28     }
06:42:28     
06:42:28     Node.js v22.0.0-pre
06:42:28   ...

Interestingly the test has a check for disk space but the test still failed which suggests either the check is wrong or the space was filled while the test was running between the check and subsequent usage.

if (!tmpdir.hasEnoughSpace(kStringMaxLength)) {
common.skip(`Not enough space in ${tmpdir.path}`);
}

@pluris
Copy link
Contributor

pluris commented Dec 13, 2023

It's actually using more capacity in stream.write() than is written to kStringMaxLength.
There are 201 buffers used in the for loop.

if (!tmpdir.hasEnoughSpace(kStringMaxLength)) {
common.skip(`Not enough space in ${tmpdir.path}`);
}

const size = kStringMaxLength / 200;
const a = Buffer.alloc(size, 'a');
let expectedSize = 0;
for (let i = 0; i < 201; i++) {
stream.write(a, (err) => { assert.ifError(err); });
expectedSize += a.length;
}

nodejs-github-bot pushed a commit that referenced this issue Dec 25, 2023
PR-URL: #51141
Refs: #51133
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Deokjin Kim <deokjin81.kim@gmail.com>
RafaelGSS pushed a commit that referenced this issue Jan 2, 2024
PR-URL: #51141
Refs: #51133
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Deokjin Kim <deokjin81.kim@gmail.com>
richardlau pushed a commit that referenced this issue Mar 25, 2024
PR-URL: #51141
Refs: #51133
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Deokjin Kim <deokjin81.kim@gmail.com>
lukins-cz pushed a commit to lukins-cz/OS-Aplet-node that referenced this issue Jun 1, 2024
PR-URL: nodejs#51141
Refs: nodejs#51133
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Deokjin Kim <deokjin81.kim@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flaky-test Issues and PRs related to the tests with unstable failures on the CI. macos Issues and PRs related to the macOS platform / OSX.
Projects
None yet
Development

No branches or pull requests

3 participants