Skip to content

Migrate to ESLint 9 with flat config#207

Open
Copilot wants to merge 5 commits intomainfrom
copilot/migrate-to-eslint-9
Open

Migrate to ESLint 9 with flat config#207
Copilot wants to merge 5 commits intomainfrom
copilot/migrate-to-eslint-9

Conversation

Copy link
Contributor

Copilot AI commented Mar 11, 2026

Summary

Migrates the project from ESLint 8 to ESLint 9 using the new flat config format.

Changes

Dependencies (package.json)

  • Replaced eslint@^8.57.0eslint@^9.0.0
  • Removed @typescript-eslint/eslint-plugin@^7.13.1 and @typescript-eslint/parser@^7.13.1
  • Added typescript-eslint@^8.57.0 (new unified package supporting ESLint 8, 9, and 10)
  • Added @stylistic/eslint-plugin@^5.10.0 (TypeScript stylistic rules moved here in typescript-eslint v8: semi, indent, member-delimiter-style)
  • Added globals@^15.15.0 (for Node.js global declarations in flat config)

ESLint Configuration

  • Created root eslint.config.mjs in ESLint 9 flat config format, replacing .eslintrc.base.json
  • Created per-package eslint.config.mjs for each subpackage (tsc, tooling, protocol, language-service, lsif, sqlite, npm, tsc-tests) that imports the root config and adds package-specific TypeScript projectService.defaultProject settings
  • Removed all legacy .eslintrc.json and .eslintignore files

Notes

  • The projectService.defaultProject setting in per-package configs ensures type-aware rules like @typescript-eslint/no-floating-promises work correctly with each package's tsconfig.json
  • Pre-existing lint warnings (indentation) remain unchanged — they existed before the migration
  • Pre-existing build failures (better-sqlite3 native module and @types/node incompatibilities) are unrelated to this ESLint migration

Security Summary

No security vulnerabilities introduced. All new dependencies were verified against the GitHub Advisory Database with no issues found.

Copilot AI and others added 2 commits March 11, 2026 19:52
Co-authored-by: rzhao271 <7199958+rzhao271@users.noreply.github.com>
@rzhao271
Copy link

@copilot redo to fix merge conflicts and broken CI

…d engines

Co-authored-by: rzhao271 <7199958+rzhao271@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Mar 18, 2026

@copilot redo to fix merge conflicts and broken CI

Done in b425a7b. Synced with main (PR #208) by updating: CI YAML files to Node.js 22.22.0, @types/node to 22.19.15, sqlite imports back to vscode-languageserver-types, and protocol/language-service engines to >=22. The ESLint 9 migration changes are preserved on top.

Copilot AI requested a review from rzhao271 March 18, 2026 17:58
@rzhao271 rzhao271 marked this pull request as ready for review March 18, 2026 17:59
@rzhao271
Copy link

@copilot redo dependency installation to resolve merge conflicts

… and resolve merge conflicts

Co-authored-by: rzhao271 <7199958+rzhao271@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Mar 18, 2026

@copilot redo dependency installation to resolve merge conflicts

Done in 5f7b695. Regenerated package-lock.json using --lockfile-version=2 to match upstream's format, minimizing divergence from main and resolving the merge conflicts.

Copilot AI requested a review from rzhao271 March 18, 2026 18:06
@rzhao271 rzhao271 enabled auto-merge (squash) March 18, 2026 18:07
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.

2 participants