Skip to content

Conversation

@tylerbutler
Copy link
Member

@tylerbutler tylerbutler commented Oct 10, 2025

Updates @typescript-eslint packages from v7 to v8 with necessary rule migrations and configuration adjustments.

Changes

  • Update @typescript-eslint/eslint-plugin and @typescript-eslint/parser to v8
  • Migrate rule: no-throw-literalonly-throw-error
  • Remove deprecated and deleted rules: ban-types, no-empty-interface, and others
    • I removed all typescript-eslint rules that are deleted or deprecated. This resulted in some trivial changes to the config of some rules (rulesets often keep the old, even deleted, rules around for awhile "just in case" -- they just set them to "off" -- so we'll still see them in the printed configs).
  • Update codebase for new rule requirements (explicit returns, type annotations)

Test plan

  • CI passes with updated ESLint configuration
  • All lint errors resolved across codebase

Copilot AI review requested due to automatic review settings October 10, 2025 00:18
@github-actions github-actions bot added the area: build Build related issues label Oct 10, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Updates the TypeScript ESLint plugin from v7.18.0 to v8.18.2, adapting configuration to handle breaking changes in the new major version. The update removes deprecated rules and introduces new ones for better TypeScript code quality.

Key changes:

  • Upgrade TypeScript ESLint plugin and parser to v8.18.2
  • Replace deprecated no-throw-literal with only-throw-error rule
  • Remove deprecated ban-types and no-empty-interface rules and their disables
  • Add no-restricted-types rule to discourage null usage in favor of undefined

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated no comments.

File Description
package.json Updates TypeScript ESLint dependencies to v8.18.2
base.js Removes deprecated rule configurations and adds new v8-compatible rules
Files not reviewed (1)
  • common/build/eslint-config-fluid/pnpm-lock.yaml: Language not supported

@tylerbutler tylerbutler force-pushed the 3-update-typescript-eslint branch from 0c485e8 to 286a85b Compare November 6, 2025 03:11
@tylerbutler tylerbutler requested a review from a team as a code owner November 6, 2025 03:11
@github-actions github-actions bot added the public api change Changes to a public API label Nov 12, 2025
Comment on lines 37 to 39
// FIXME: Is this the right fix? There are lots of errors here.
"@fluid-internal/fluid/no-unchecked-record-access": "off",

Copy link
Member Author

Choose a reason for hiding this comment

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

@jason-ha This rule seems to be triggered on a lot of presence code with the typescript-eslint upgrade in this PR. My hunch is they're false positives, but I didn't look closely. I am not inclined to do a deep investigation on most issues until we're on a stable/supported version of the stack. But since this is a custom rule, it could also be a bug there, or something else.

I could also make them warnings for now instead of disabling, so they could be investigated more deeply. Or if you think a deeper investigation is warranted and should be blocking, I'm open to discussing.

@Josmithr FYI.

Copy link
Contributor

Choose a reason for hiding this comment

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

Last I recall, that rule still had lots of issues and is disabled in a lot of places across the repo. Could use some investment, I think.

@github-actions
Copy link
Contributor

🔗 No broken links found! ✅

Your attention to detail is admirable.

linkcheck output


> fluid-framework-docs-site@0.0.0 ci:check-links /home/runner/work/FluidFramework/FluidFramework/docs
> start-server-and-test "npm run serve -- --no-open" 3000 check-links

1: starting server using command "npm run serve -- --no-open"
and when url "[ 'http://127.0.0.1:3000' ]" is responding with HTTP status code 200
running tests using command "npm run check-links"


> fluid-framework-docs-site@0.0.0 serve
> docusaurus serve --no-open

[SUCCESS] Serving "build" directory at: http://localhost:3000/

> fluid-framework-docs-site@0.0.0 check-links
> linkcheck http://localhost:3000 --skip-file skipped-urls.txt

Crawling...

Stats:
  249533 links
    1776 destination URLs
    2013 URLs ignored
       0 warnings
       0 errors


@tylerbutler tylerbutler merged commit 1d81d1a into microsoft:main Nov 25, 2025
44 checks passed
@tylerbutler tylerbutler deleted the 3-update-typescript-eslint branch November 25, 2025 22:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: build Build related issues area: dds: propertydds area: dds: tree area: dds Issues related to distributed data structures area: driver Driver related issues area: examples Changes that focus on our examples area: framework Framework is a tag for issues involving the developer framework. Eg Aqueduct area: loader Loader related issues area: odsp-driver area: runtime Runtime related issues area: tests Tests to add, test infrastructure improvements, etc base: main PRs targeted against main branch dependencies Pull requests that update a dependency file public api change Changes to a public API

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants