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

fix: update eslint-plugin-n to latest which no longer use deprecated method #756

Merged

Conversation

abiriadev
Copy link
Contributor

@abiriadev abiriadev commented Jul 18, 2024

fixes #752

The current version of XO uses [email protected], which invokes a deprecated method in Node.js v22. For more information about the exact cause and deprecated version, please see #752.

Before

We can see a deprecation warning at the end of the report.

node cli.js

  config/plugins.cjs:35:335:3  Unexpected todo comment: TODO: Remove this override at some....        no-warning-comments141:3  Unexpected todo comment: TODO: Restore when it becomes safer:....      no-warning-comments
    165:3  Unexpected todo comment: TODO: Disabled for now as I don't have....    no-warning-comments
  ⚠  177:3  Unexpected todo comment: TODO: Remove this override when the rule....  no-warning-comments
  ⚠  180:3  Unexpected todo comment: TODO: Temporarily disabled until it....       no-warning-comments
  ⚠  183:3  Unexpected todo comment: TODO: Temporarily disabled as the rule....    no-warning-comments
  ⚠  233:5  Unexpected todo comment: TODO: Buggy..                                 no-warning-comments

  cli.js:119:1
  ⚠  119:1  Unexpected todo comment: TODO: Fix this properly instead of the....    no-warning-comments

  8 warnings
(node:1071047) [DEP0180] DeprecationWarning: fs.Stats constructor is deprecated.
(Use `node --trace-deprecation ...` to show where the warning was created)

After

after updateing eslint-plugin-n, the warning is gone as expected.

node cli.js

  config/plugins.cjs:35:3
  ⚠   35:3  Unexpected todo comment: TODO: Remove this override at some....        no-warning-comments
  ⚠  141:3  Unexpected todo comment: TODO: Restore when it becomes safer:....      no-warning-comments
  ⚠  165:3  Unexpected todo comment: TODO: Disabled for now as I don't have....    no-warning-comments
  ⚠  177:3  Unexpected todo comment: TODO: Remove this override when the rule....  no-warning-comments
  ⚠  180:3  Unexpected todo comment: TODO: Temporarily disabled until it....       no-warning-comments
  ⚠  183:3  Unexpected todo comment: TODO: Temporarily disabled as the rule....    no-warning-comments
  ⚠  233:5  Unexpected todo comment: TODO: Buggy..                                 no-warning-comments

  cli.js:119:1
  ⚠  119:1  Unexpected todo comment: TODO: Fix this properly instead of the....    no-warning-comments

  8 warnings

@abiriadev abiriadev marked this pull request as ready for review July 18, 2024 05:13
@sindresorhus sindresorhus merged commit fb8f33f into xojs:main Jul 18, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Upgrade eslint-plugin-n to support latest Node.js environment
2 participants