GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — src: expand --process-timeout output to include workers by jasnell · Pull Request #67712 · nodejs/node

Conversation

@jasnell

@jasnell jasnell commented Nov 22, 2026

Copy link
Copy Markdown
Member

When a process is interrupted using --process-timeout, the output would print the resources and stack of the main thread. If the thing keeping the process alive was a worker thread, or if the worker thread was interrupted, there was no diagnostic output.

This adds an additional --process-timeout-worker-stacks flag that includes the worker details. We don't necessarily want to include workers every time because if there's a large number of workers the output could become quite noisy.

$ ./node --process-timeout=1s --process-timeout-worker-stacks -pe "new worker_threads.Worker('setTimeout(()=>{}, 10000)', {eval:true})"
(node:358015) Process timed out after 1s (--process-timeout). Exiting with code 124.
Main thread was not executing JavaScript.
Resources keeping the event loop alive:
    Worker (thread 1, name 'WorkerThread')
Worker thread 1 (name 'WorkerThread') was not executing JavaScript.
Resources keeping its event loop alive:
    Timeout (next due in 9028ms)

$ ./node --process-timeout=1s --process-timeout-worker-stacks -pe "new worker_threads.Worker('while(true){}', {eval:true})"
(node:358032) Process timed out after 1s (--process-timeout). Exiting with code 124.
Main thread was not executing JavaScript.
Resources keeping the event loop alive:
    Worker (thread 1, name 'WorkerThread')
Worker thread 1 (name 'WorkerThread') was executing JavaScript:
    at [worker eval]:1:1
    at runScriptInThisContext (node:internal/vm:219:10)
    at node:internal/process/execution:485:12
    at [worker eval]-wrapper:6:24
    at runScriptInContext (node:internal/process/execution:483:60)
    at evalFunction (node:internal/process/execution:317:30)
    at evalTypeScript (node:internal/process/execution:329:3)
    at node:internal/main/worker_thread:201:9
    at [nodejs.internal.kHybridDispatch] (node:internal/event_target:876:20)
    at node:internal/per_context/messageport:23:28
No resources keeping its event loop alive were found

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@jasnell
jasnell requested a review from mcollina November 22, 2026 22:09
@jasnell jasnell added the semver-minor PRs that contain new features and should be released in the next minor version. label Nov 22, 2026
@nodejs-github-bot

nodejs-github-bot commented Nov 22, 2026

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/config
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. config Issues and PRs related to Node.js configuration and feature settings. needs-ci PRs that need a full CI run. labels Nov 22, 2026
gurgunday
gurgunday reviewed Nov 22, 2026
View reviewed changes

@gurgunday gurgunday left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, but lint is failing

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

jasnell reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@jasnell
src: expand --process-timeout output to include workers
6740446
When a process is interrupted using `--process-timeout`, the output
would print the resources and stack of the main thread. If the
thing keeping the process alive was a worker thread, or if the
worker thread was interrupted, there was no diagnostic output.

This adds an additional `--process-timeout-worker-stacks` flag
that includes the worker details. We don't necessarily want to
include workers every time because if there's a large number of
workers the output could become quite noisy.

Signed-off-by: James M Snell <[email protected]>
Assisted-by: Claude
@jasnell
jasnell force-pushed the jasnell/process-timeout-worker-details branch from 720e0c2 to 6740446 Compare November 22, 2026 23:21
@jasnell
jasnell requested a review from gurgunday November 22, 2026 23:34
@codecov

codecov Bot commented Nov 23, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 87.73585% with 13 lines in your changes missing coverage. Please review.
✅ Project coverage is 90.53%. Comparing base (2566f1b) to head (6740446).
⚠️ Report is 47 commits behind head on main.

Files with missing lines Patch % Lines
src/node_watchdog.cc 87.00% 5 Missing and 8 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #67712      +/-   ##
==========================================
- Coverage   90.54%   90.53%   -0.01%     
==========================================
  Files         801      801              
  Lines      284119   284210      +91     
  Branches    54882    54886       +4     
==========================================
+ Hits       257257   257320      +63     
- Misses      17022    17051      +29     
+ Partials     9840     9839       -1     
Files with missing lines Coverage Δ
src/node_options.cc 88.28% <100.00%> (+0.04%) ⬆️
src/node_options.h 95.78% <100.00%> (+0.01%) ⬆️
src/node_watchdog.cc 80.32% <87.00%> (+1.00%) ⬆️

... and 32 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

mcollina
mcollina approved these changes Nov 24, 2026
View reviewed changes

@mcollina mcollina left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@mcollina mcollina added the request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. label Nov 24, 2026
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. label Nov 24, 2026
@nodejs-github-bot

nodejs-github-bot commented Nov 24, 2026 •
edited by jasnell
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Collaborator

CI: https://ci.nodejs.org/job/node-test-pull-request/79471/ 💚

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@jasnell jasnell added author ready PRs with CI started, the required approvals, and no outstanding review comments. commit-queue PRs queued for automated landing through the Commit Queue. labels Nov 24, 2026
@jasnell

jasnell commented Nov 24, 2026

Copy link
Copy Markdown
Member Author

@gurgunday ... you gave an LGTM but didn't actually approve the PR. Can I ask you to PTAL.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@nodejs-github-bot nodejs-github-bot added the lacks-second-approval Commit Queue PRs awaiting a second collaborator approval or completion of the required wait. label Nov 24, 2026
christianaurichzm
christianaurichzm approved these changes Nov 25, 2026
View reviewed changes
@nodejs-github-bot
nodejs-github-bot merged commit b4e974c into nodejs:main Nov 25, 2026
72 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@nodejs-github-bot

nodejs-github-bot commented Nov 25, 2026

Copy link
Copy Markdown
Collaborator

Landed in b4e974c

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@nodejs-github-bot nodejs-github-bot removed commit-queue PRs queued for automated landing through the Commit Queue. lacks-second-approval Commit Queue PRs awaiting a second collaborator approval or completion of the required wait. labels Nov 25, 2026
aduh95 added a commit that referenced this pull request Nov 25, 2026
@aduh95
2026-11-26, Version 27.0.0-alpha.0.2.0 (Alpha)
67d9357
Notable changes:

doc:
  * deprecate `util.TextDecoder` and `util.TextEncoder` (LiviaMedeiros) #67461
http2:
  * (SEMVER-MINOR) add writeProcessing to compat response (Yuya Inoue) #67728
  * (SEMVER-MINOR) add missing setHeaders (jakecastelli) #67597
  * (SEMVER-MINOR) add callback to informational header methods (Yuya Inoue) #67470
lib:
  * (SEMVER-MINOR) graduate the --process-timeout option (James M Snell) #67506
os:
  * (SEMVER-MINOR) expose `guessFileDescriptorType` (Vlad Frangu) #58060
sqlite:
  * (SEMVER-MINOR) throw ERR_NO_SQLITE without SQLite support (Christian Aurich Zanettini Martins) #67727
  * (SEMVER-MINOR) add statement.columnCount getter (Guilherme Araújo) #67658
  * mark as stable (Christian Aurich Zanettini Martins) #67654
src:
  * (SEMVER-MINOR) expand --process-timeout output to include workers (James M Snell) #67712
  * (SEMVER-MINOR) restore tty state on exit only if changed (Matteo Collina) #66753
tls:
  * (SEMVER-MINOR) docs-deprecate TLS renegotiation, add allowRenegotiation opt-in (Tim Perry) #67532

PR-URL: #67757
@aduh95 aduh95 mentioned this pull request Nov 25, 2026
2026-11-25, Version 27.0.0-alpha.0.2.0 (Alpha) #67757
Merged
@inoway46 inoway46 mentioned this pull request Nov 26, 2026
test: deflake test-process-timeout-worker-stacks #67783
Open
aduh95 added a commit that referenced this pull request Nov 26, 2026
@aduh95
2026-11-26, Version 27.0.0-alpha.0.2.0 (Alpha)
4325ce0
Notable changes:

doc:
  * deprecate `util.TextDecoder` and `util.TextEncoder` (LiviaMedeiros) #67461
http2:
  * (SEMVER-MINOR) add writeProcessing to compat response (Yuya Inoue) #67728
  * (SEMVER-MINOR) add missing setHeaders (jakecastelli) #67597
  * (SEMVER-MINOR) add callback to informational header methods (Yuya Inoue) #67470
lib:
  * (SEMVER-MINOR) graduate the --process-timeout option (James M Snell) #67506
os:
  * (SEMVER-MINOR) expose `guessFileDescriptorType` (Vlad Frangu) #58060
sqlite:
  * (SEMVER-MINOR) throw ERR_NO_SQLITE without SQLite support (Christian Aurich Zanettini Martins) #67727
  * (SEMVER-MINOR) add statement.columnCount getter (Guilherme Araújo) #67658
  * mark as stable (Christian Aurich Zanettini Martins) #67654
src:
  * (SEMVER-MINOR) expand --process-timeout output to include workers (James M Snell) #67712
  * (SEMVER-MINOR) restore tty state on exit only if changed (Matteo Collina) #66753
tls:
  * (SEMVER-MINOR) docs-deprecate TLS renegotiation, add allowRenegotiation opt-in (Tim Perry) #67532

PR-URL: #67757
gabylb pushed a commit to gabylb/node that referenced this pull request Nov 27, 2026
@jasnell @gabylb
src: expand --process-timeout output to include workers
ca6474b
When a process is interrupted using `--process-timeout`, the output
would print the resources and stack of the main thread. If the
thing keeping the process alive was a worker thread, or if the
worker thread was interrupted, there was no diagnostic output.

This adds an additional `--process-timeout-worker-stacks` flag
that includes the worker details. We don't necessarily want to
include workers every time because if there's a large number of
workers the output could become quite noisy.

Signed-off-by: James M Snell <[email protected]>
Assisted-by: Claude
PR-URL: nodejs#67712
Reviewed-By: Matteo Collina <[email protected]>
Reviewed-By: Christian Aurich Zanettini Martins <[email protected]>
gabylb pushed a commit to gabylb/node that referenced this pull request Nov 27, 2026
@aduh95 @gabylb
2026-11-26, Version 27.0.0-alpha.0.2.0 (Alpha)
369cdc7
Notable changes:

doc:
  * deprecate `util.TextDecoder` and `util.TextEncoder` (LiviaMedeiros) nodejs#67461
http2:
  * (SEMVER-MINOR) add writeProcessing to compat response (Yuya Inoue) nodejs#67728
  * (SEMVER-MINOR) add missing setHeaders (jakecastelli) nodejs#67597
  * (SEMVER-MINOR) add callback to informational header methods (Yuya Inoue) nodejs#67470
lib:
  * (SEMVER-MINOR) graduate the --process-timeout option (James M Snell) nodejs#67506
os:
  * (SEMVER-MINOR) expose `guessFileDescriptorType` (Vlad Frangu) nodejs#58060
sqlite:
  * (SEMVER-MINOR) throw ERR_NO_SQLITE without SQLite support (Christian Aurich Zanettini Martins) nodejs#67727
  * (SEMVER-MINOR) add statement.columnCount getter (Guilherme Araújo) nodejs#67658
  * mark as stable (Christian Aurich Zanettini Martins) nodejs#67654
src:
  * (SEMVER-MINOR) expand --process-timeout output to include workers (James M Snell) nodejs#67712
  * (SEMVER-MINOR) restore tty state on exit only if changed (Matteo Collina) nodejs#66753
tls:
  * (SEMVER-MINOR) docs-deprecate TLS renegotiation, add allowRenegotiation opt-in (Tim Perry) nodejs#67532

PR-URL: nodejs#67757
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@mcollina mcollina mcollina approved these changes
@christianaurichzm christianaurichzm christianaurichzm approved these changes
@gurgunday gurgunday Awaiting requested review from gurgunday

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

author ready PRs with CI started, the required approvals, and no outstanding review comments. c++ Issues and PRs that require attention from people who are familiar with C++. config Issues and PRs related to Node.js configuration and feature settings. needs-ci PRs that need a full CI run. semver-minor PRs that contain new features and should be released in the next minor version.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

5 participants

@jasnell @nodejs-github-bot @mcollina @christianaurichzm @gurgunday
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.