Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fs: only show deprecation warning when error code matches #56549

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

aduh95
Copy link
Contributor

@aduh95 aduh95 commented Jan 10, 2025

The deprecation is only for invalid types, it could be confusing the warning show up for an unrelated error.

Refs: #55753

@aduh95 aduh95 added dont-land-on-v18.x PRs that should not land on the v18.x-staging branch and should not be released in v18.x. dont-land-on-v20.x PRs that should not land on the v20.x-staging branch and should not be released in v20.x. dont-land-on-v22.x PRs that should not land on the v22.x-staging branch and should not be released in v22.x. dont-land-on-v23.x PRs that should not land on the v23.x-staging branch and should not be released in v23.x. labels Jan 10, 2025
@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 Jan 10, 2025
Copy link
Member

@BridgeAR BridgeAR left a comment

Choose a reason for hiding this comment

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

I believe all Node.js errors should trigger the warning and only programmer errors in Node.js code should not be caught. Is that correct? We don't yet have such utility method to check that. We could however check for any error code existence. It should not exist on regular programmer errors.

Copy link

codecov bot commented Jan 10, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.16%. Comparing base (529b56e) to head (6f62176).

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #56549   +/-   ##
=======================================
  Coverage   89.16%   89.16%           
=======================================
  Files         662      662           
  Lines      191746   191746           
  Branches    36902    36901    -1     
=======================================
+ Hits       170970   170972    +2     
  Misses      13632    13632           
+ Partials     7144     7142    -2     
Files with missing lines Coverage Δ
lib/fs.js 98.30% <100.00%> (ø)

... and 24 files with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dont-land-on-v18.x PRs that should not land on the v18.x-staging branch and should not be released in v18.x. dont-land-on-v20.x PRs that should not land on the v20.x-staging branch and should not be released in v20.x. dont-land-on-v22.x PRs that should not land on the v22.x-staging branch and should not be released in v22.x. dont-land-on-v23.x PRs that should not land on the v23.x-staging branch and should not be released in v23.x. 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