nodejs / node

Node.js JavaScript runtime ✨🐢🚀✨
https://nodejs.org
Other
106.61k stars 29.07k forks source link

Flaky `test-worker-arraybuffer-zerofill` with V8 12.2 #52274

Open targos opened 5 months ago

targos commented 5 months ago

Test

test-worker-arraybuffer-zerofill

Platform

No response

Console output

22:42:18 not ok 3801 parallel/test-worker-arraybuffer-zerofill
22:42:18   ---
22:42:18   duration_ms: 300091.91200
22:42:18   severity: fail
22:42:18   exitcode: -15
22:42:18   stack: |-
22:42:18     timeout
22:42:18   ...

Build links

Additional information

test-worker-arraybuffer-zerofill: this could be a real bug, or some timing assumptions being broken/messages getting lost (which may also be a real bug). We can mark it as flaky for now, and add some logs in the test to help debugging.

Originally posted by @joyeecheung in https://github.com/nodejs/node/issues/51362#issuecomment-2023338163

anonrig commented 1 week ago

This is still flaky https://ci.nodejs.org/job/node-test-commit-linux-containered/45768/nodes=ubuntu2204_sharedlibs_icu_x64/testReport/junit/(root)/parallel/test_worker_arraybuffer_zerofill_/

jasnell commented 1 week ago

@addaleax ... in test-worker-arraybuffer-zerofill.js... do you happen to remember why the test needed to allocate such huge buffers so often?

function allocBuffers() {
  Buffer.allocUnsafe(32 * 1024 * 1024);
}

const interval = setInterval(allocBuffers, 0);

I think this is what is leading to the timeout flakiness in the test.

This file was last changed five years ago so I'll understand if you don't remember ;-)

Btw, I'm assuming it's to ensure that the allocation is expensive enough to ensure that it is likely still running when the other thread allocates?