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
{{ message }}
Repository navigation
🤖 tests: eventLoopYielder "yield lets due timers run" flakes on a stalled runner #6822
src/node/utils/concurrency/eventLoopYielder.test.ts › "yield lets due timers run once the budget is used" failed in the merge queue and dropped #6804 (run 38777134519, job 116567701971, Test / Unit (3/6)):
expect(yielder.isDue()).toBe(false) // line 19
Expected: false
Received: true
Cause (from the code): the test uses a 5 ms budget (new EventLoopYielder(5)). After await yielder.yield() resets lastYieldAt, a stall of 5 ms or more before the next line (CPU quota throttling on a shared runner) makes isDue() true again. The last assertion checks wall time, not the contract.
Fix: check the reset without a wall-clock race, for example by comparing isDue() right after yield() with a fake performance.now, or by dropping the last assertion (the timer assertion already pins the contract).
Generated with xum • Model: anthropic:claude-opus-5-5 • Thinking: high
Activity