Skip to content

Conversation

@Renegade334
Copy link
Member

@Renegade334 Renegade334 commented Jan 28, 2026

The current warnings for events.once() focus heavily on process.nextTick().

The footgun really appears in any case where sequential await events.once(...) statements are used, as execution won't resume within the suspended async function until the current call stack has completed, by which point multiple events may have been emitted. This is just as likely to be run into in general execution, rather than with process.nextTick() specifically.

Refs: #34220

@nodejs-github-bot nodejs-github-bot added doc Issues and PRs related to the documentations. events Issues and PRs related to the events subsystem / EventEmitter. labels Jan 28, 2026
@Renegade334 Renegade334 requested a review from jasnell January 28, 2026 23:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc Issues and PRs related to the documentations. events Issues and PRs related to the events subsystem / EventEmitter.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants