Skip to content

fix(deps): upgrade eslint and plugins to 9.39.4#201701

Open
maxkoryukov wants to merge 3 commits intowwebjs:mainfrom
volebo:feat/deps-upgrade-eslint-10.mk
Open

fix(deps): upgrade eslint and plugins to 9.39.4#201701
maxkoryukov wants to merge 3 commits intowwebjs:mainfrom
volebo:feat/deps-upgrade-eslint-10.mk

Conversation

@maxkoryukov
Copy link
Copy Markdown

Description

This PR changes (I hope) nothing in the package's code, but it upgrades the eslint to the newest v10.2.0 with the flat config structure.

Testing Summary

I converted the old .eslintrc.json and .eslintignore files into the newer "flat" format of eslint config - eslint.config.mjs.

.mjs for the config file - because today it is very common to share/copy/paste eslint configs and examples in ESM format.

In order to test - i took my previous PRs "as is" and applied npm run lint:fix - and the new 10.2.0 eslint fixed the code.

I've added @stylistic plugin as well, with its "recommended" config. Because of notes in the migration guide

ESLint has officially deprecated all built-in formatting and stylistic rules as of version 8.53.0

The "Prettier" integration is preserved, and as its documentation says - it is added to the end of the "flat" config (this way "Prettier" config overrides some options and make Eslint and Prettier work harmoniously)

Type of Change

  • Dependency change (package changes such as removals, upgrades, or additions)
  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Non-code change (documentation, README, etc.)

Checklist

  • My code follows the style guidelines of this project.
  • All new and existing tests pass (npm test).
  • Typings (e.g. index.d.ts) have been updated if necessary.
  • Usage examples (e.g. example.js) / documentation have been updated if applicable.

@github-actions github-actions bot added dependencies Dependency updates api changes API modifications tests Test related build Build system utility Utility code labels Apr 7, 2026
setup(client) {
this.client = client;
}

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

there are "stylistic changes":

  1. add empty lines
  2. add a <space> for inline comments
  3. replace unused err (or _, or other names) with ignoredError
  4. and there are two lines i didn't want to change - so i've added "eslint-ignore" to them

});

// eslint-disable-next-line mocha/no-skipped-tests
// eslint-disable-next-line mocha/no-pending-tests
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

this rule was renamed in the newest versions of the eslint-mocha plugin

@github-actions github-actions bot added ci CI pipeline infra Infrastructure labels Apr 7, 2026
- uses: actions/checkout@v2
- name: Install node v14
uses: actions/setup-node@v2
- uses: actions/checkout@v4
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

and here are the most dangerous changes, because it affects the "Pipeline"

i've upgraded the task to use "actions@v4" and instead of using Node14 - Node24

because:

  1. it is linting, not "running the package"
  2. it is 2026;) and Node14 is "end of life" after Feb 16, 2023

Copy link
Copy Markdown
Member

@2hoch1 2hoch1 Apr 7, 2026

Choose a reason for hiding this comment

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

This workflow has been replaced by tests and will be removed in the future. #127111

Copy link
Copy Markdown
Author

@maxkoryukov maxkoryukov Apr 7, 2026

Choose a reason for hiding this comment

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

i needed to update it because the pipeline was failing

but i can remove it from the PR

i've updated the PR today, but i still didn't remove GH Action update

package.json Outdated
"chai-as-promised": "^7.1.1",
"dotenv": "^16.0.0",
"eslint": "^8.4.1",
"eslint": "^10.2.0",
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Using the latest version isn’t always the best choice. Downgrade to eslint@9.39.4 for a more stable release.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

DONE!

@2hoch1 2hoch1 mentioned this pull request Apr 7, 2026
9 tasks
@maxkoryukov maxkoryukov force-pushed the feat/deps-upgrade-eslint-10.mk branch from 4db9fb4 to 38b8177 Compare April 7, 2026 19:10
@maxkoryukov
Copy link
Copy Markdown
Author

@2hoch1 thanks for reviewing so fast! and thanks for adding the #201702 (stale deps) - i didn't notice this bug

and i've downgraded eslint to @9.39.4

in order to test i put this whole repo into a "node:24" docker image without eslint pre-installed, ran npm i , ensured that npm run lint -- --version returns

eslint
9.39.4

and checked the linting output.

after fixing minor issues (some // eslint ignore aren't required for eslint@9), the linter stopped to show warnings - and i pushed the PR for a new review.

@2hoch1
Copy link
Copy Markdown
Member

2hoch1 commented Apr 7, 2026

Your changes to lint.yml are blocking the ESLint workflow. Reverting the change should fix it.

@maxkoryukov
Copy link
Copy Markdown
Author

maxkoryukov commented Apr 7, 2026

Your changes to lint.yml are blocking the ESLint workflow. Reverting the change should fix it.

without this changes the Action fails, and the whole PR is considered "failing"

but let me remove those changes from the PR

UPD: DONE

@maxkoryukov maxkoryukov force-pushed the feat/deps-upgrade-eslint-10.mk branch from 38b8177 to 1b099ce Compare April 7, 2026 20:31
@github-actions github-actions bot removed ci CI pipeline infra Infrastructure labels Apr 7, 2026
@maxkoryukov maxkoryukov changed the title fix(deps): upgrade eslint and plugins to 10.2.0 fix(deps): upgrade eslint and plugins to 9.39.4 Apr 7, 2026
BenyFilho
BenyFilho previously approved these changes Apr 7, 2026
@BenyFilho BenyFilho added the approved Confirmed by maintainers label Apr 7, 2026
@maxkoryukov
Copy link
Copy Markdown
Author

so, yes, i rolled back changes in the "gitlab actions" and now the "Lint/ Eslint(pull_request)" Check fails in the GH Actions

@BenyFilho BenyFilho dismissed their stale review April 7, 2026 20:40

Error, it was only to approve workflow

@BenyFilho BenyFilho removed the approved Confirmed by maintainers label Apr 7, 2026
@2hoch1
Copy link
Copy Markdown
Member

2hoch1 commented Apr 7, 2026

Your workflow didn’t run because you are a first‑time contributor.

The current error is caused by the lint.yml setup, since that workflow still uses Node@14 while @stylistic/eslint-plugin requires Node@18. That is why the tests workflow is passing but the lint workflow is failing.

You can try adjusting the lint.yml. The bump is in fact necessary, even if the workflow gets removed afterward.

import globals from 'globals';
import pluginEslintJs from '@eslint/js';
import pluginMocha from 'eslint-plugin-mocha';
import pluginStylistic from '@stylistic/eslint-plugin';
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@stylistic/eslint-plugin may cause formatting conflicts with Prettier.

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

Labels

api changes API modifications build Build system dependencies Dependency updates tests Test related utility Utility code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants