Skip to content

fs: abort in-flight stat operations#63142

Open
mertcanaltin wants to merge 1 commit intonodejs:mainfrom
mertcanaltin:mert/fs-stat-inflight-fix
Open

fs: abort in-flight stat operations#63142
mertcanaltin wants to merge 1 commit intonodejs:mainfrom
mertcanaltin:mert/fs-stat-inflight-fix

Conversation

@mertcanaltin
Copy link
Copy Markdown
Member

Follow-up to #57775. The signal option only honored the pre-aborted case (#57775 (comment) by @Renegade334). This wires the signal as an abort listener so fs.stat callbacks reject with AbortError when the signal fires mid-request.

Refs: #57775

@nodejs-github-bot nodejs-github-bot added fs Issues and PRs related to the fs subsystem / file system. needs-ci PRs that need a full CI run. labels May 6, 2026
@mertcanaltin mertcanaltin force-pushed the mert/fs-stat-inflight-fix branch from 4425502 to e4d317e Compare May 6, 2026 05:18
@bakkot
Copy link
Copy Markdown
Contributor

bakkot commented May 6, 2026

Drive-by: this looks like it's still not actually canceling the underlying call, which would involve invoking uv_cancel somewhere.

Signed-off-by: Mert Can Altin <mertgold60@gmail.com>
@mertcanaltin mertcanaltin force-pushed the mert/fs-stat-inflight-fix branch from e4d317e to 8149c79 Compare May 7, 2026 19:42
@codecov
Copy link
Copy Markdown

codecov Bot commented May 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.03%. Comparing base (1fd4949) to head (8149c79).

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #63142   +/-   ##
=======================================
  Coverage   90.03%   90.03%           
=======================================
  Files         713      713           
  Lines      224699   224720   +21     
  Branches    42473    42490   +17     
=======================================
+ Hits       202310   202334   +24     
+ Misses      14179    14172    -7     
- Partials     8210     8214    +4     
Files with missing lines Coverage Δ
lib/fs.js 98.21% <100.00%> (+0.01%) ⬆️

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

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

Labels

fs Issues and PRs related to the fs subsystem / file system. needs-ci PRs that need a full CI run.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants