[Snyk] Security upgrade eslint from 7.31.0 to 9.1.0#74
[Snyk] Security upgrade eslint from 7.31.0 to 9.1.0#74
Conversation
The following vulnerabilities are fixed with an upgrade: - https://snyk.io/vuln/SNYK-JS-MINIMATCH-15353389
|
This is a major version upgrade from ESLint v7 to v9, which includes two sets of significant breaking changes. Manual intervention is required to migrate configuration files and address rule changes. Key Breaking Changes in v9.0:
Key Breaking Changes in v8.0:
Recommendation: This upgrade requires a significant migration effort. Developers must rewrite their ESLint configuration to the new flat format, update their Node.js version if necessary, and verify that all plugins and custom integrations are compatible with ESLint v9. It is highly recommended to follow the official migration guides. Source: ESLint v9 Migration Guide, ESLint v8 Migration Guide
|
There was a problem hiding this comment.
Pull request overview
This PR upgrades ESLint from 7.31.0 to 9.39.3 (not 9.1.0 as stated) to address a high-severity security vulnerability (Inefficient Algorithmic Complexity in minimatch, SNYK-JS-MINIMATCH-15353389). However, this upgrade introduces a critical breaking change that will prevent the project's linting from functioning.
Changes:
- Upgrades eslint from ^7.31.0 to ^9.1.0 in package.json (resolves to 9.39.3 in yarn.lock)
- Updates yarn.lock with ESLint 9.x dependency tree, including new packages for flat config system support
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| package.json | Updates ESLint version constraint from ^7.31.0 to ^9.1.0 |
| yarn.lock | Reflects complete dependency tree changes for ESLint 9.39.3 upgrade, including new ESLint 9-specific packages |
Critical Issue: ESLint 9.x requires @typescript-eslint packages version 8.x or higher. This project currently uses @typescript-eslint/eslint-plugin and @typescript-eslint/parser version 4.28.4, which are incompatible with ESLint 9.x. The linting functionality will fail when this PR is merged without also upgrading the TypeScript ESLint packages.
Additional Issue: There's a discrepancy between the PR description (which mentions version 9.1.0) and the actual installed version (9.39.3 per yarn.lock). While the newer version is generally better, this should be clarified.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "@typescript-eslint/eslint-plugin": "^4.28.4", | ||
| "@typescript-eslint/parser": "^4.28.4", |
There was a problem hiding this comment.
This upgrade introduces a critical compatibility issue. ESLint 9.x requires @typescript-eslint packages version 8.x or higher, but this project is using @typescript-eslint/eslint-plugin and @typescript-eslint/parser version 4.28.4.
The TypeScript ESLint v4.x packages are not compatible with ESLint 9.x and will cause the linter to fail. You need to upgrade both @typescript-eslint/eslint-plugin and @typescript-eslint/parser to at least version 8.0.0 along with this ESLint upgrade.
| "@typescript-eslint/eslint-plugin": "^4.28.4", | |
| "@typescript-eslint/parser": "^4.28.4", | |
| "@typescript-eslint/eslint-plugin": "^8.0.0", | |
| "@typescript-eslint/parser": "^8.0.0", |
Snyk has created this PR to fix 1 vulnerabilities in the yarn dependencies of this project.
Snyk changed the following file(s):
package.jsonyarn.lockNote for zero-installs users
If you are using the Yarn feature zero-installs that was introduced in Yarn V2, note that this PR does not update the
.yarn/cache/directory meaning this code cannot be pulled and immediately developed on as one would expect for a zero-install project - you will need to runyarnto update the contents of the./yarn/cachedirectory.If you are not using zero-install you can ignore this as your flow should likely be unchanged.
Vulnerabilities that will be fixed with an upgrade:
SNYK-JS-MINIMATCH-15353389
Breaking Change Risk
Important
Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.
For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic
Learn how to fix vulnerabilities with free interactive lessons:
🦉 Learn about vulnerability in an interactive lesson of Snyk Learn.