Skip to content

diagnostics_channel: add generator support to tracing channel#61686

Draft
rochdev wants to merge 1 commit intonodejs:mainfrom
rochdev:trace-generator
Draft

diagnostics_channel: add generator support to tracing channel#61686
rochdev wants to merge 1 commit intonodejs:mainfrom
rochdev:trace-generator

Conversation

@rochdev
Copy link
Contributor

@rochdev rochdev commented Feb 5, 2026

Nearly all use cases can already be handled by a combination of traceSync, tracePromise and traceCallback. However, because generator functions use language constructs that cannot themselves be patched, it becomes complicated to implement support for a library author, as they would have to extract the generator and patch it, which is not something they might be comfortable doing, and it would be easy to get it wrong. The new method makes this much easier by handling the patching and setting up the channels for the function itself as well as the returned generator.

@nodejs-github-bot nodejs-github-bot added diagnostics_channel Issues and PRs related to diagnostics channel needs-ci PRs that need a full CI run. labels Feb 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

diagnostics_channel Issues and PRs related to diagnostics channel needs-ci PRs that need a full CI run.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants