Skip to content

lib: keep AbortSignal.any() timeout sources alive - #66615

Open
lazerg wants to merge 1 commit into
nodejs:mainfrom
lazerg:fix/issue-66610-any-timeout-listener
Open

lazerg wants to merge 1 commit into
nodejs:mainfrom
lazerg:fix/issue-66610-any-timeout-listener

Conversation

@lazerg

@lazerg lazerg commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

When a timeout passed to AbortSignal.any() has an abort listener added and removed, kRemoveListener drops it from gcPersistentSignals even though a composite still follows it, so after a GC the composite never aborts. This keeps the timeout in the set while it still has dependant signals.

Fixes: #66610

Signed-off-by: lazerg <lazerg2@gmail.com>
Assisted-by: Claude
@nodejs-github-bot nodejs-github-bot added the needs-ci PRs that need a full CI run. label Oct 8, 2026
@github-actions

github-actions Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

Caution

AgentScan found account activity patterns that may be consistent with automation. This is a heuristic, not proof that this pull request was opened by an agent or violates policy. AI-assisted contributions are permitted, but automated tooling must not open pull requests without advance approval, and contributors must personally understand, test, verify, and take responsibility for every submitted change. See the AgentScan analysis, AI use policy, and automation policy for additional context.

@codecov

codecov Bot commented Oct 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.45%. Comparing base (f9defa6) to head (ed41d04).
⚠️ Report is 6 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #66615      +/-   ##
==========================================
+ Coverage   90.43%   90.45%   +0.01%     
==========================================
  Files         791      791              
  Lines      276563   276588      +25     
  Branches    53115    53111       -4     
==========================================
+ Hits       250117   250174      +57     
+ Misses      16850    16816      -34     
- Partials     9596     9598       +2     
Files with missing lines Coverage Δ
lib/internal/abort_controller.js 95.42% <100.00%> (+0.02%) ⬆️

... and 31 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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agentscan:community-flagged needs-ci PRs that need a full CI run.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AbortSignal.any() stops following a timeout signal once a listener is added to the timeout and removed, so the composite never aborts after a GC

2 participants