Skip to content

Build: Fix for erroneous lint failure on @typescript-eslint/unbound-method rule#25821

Closed
TommyBrosman wants to merge 2 commits intomicrosoft:mainfrom
TommyBrosman:dedupe-pnpm-deps
Closed

Build: Fix for erroneous lint failure on @typescript-eslint/unbound-method rule#25821
TommyBrosman wants to merge 2 commits intomicrosoft:mainfrom
TommyBrosman:dedupe-pnpm-deps

Conversation

@TommyBrosman
Copy link
Contributor

@TommyBrosman TommyBrosman commented Nov 5, 2025

#25801 introduced an ESLint failure. This PR is the result of running pnpm dedupe on that revision. The failure takes the form of this error:

@fluidframework/driver-web-cache: ESLint: 8.57.1
@fluidframework/driver-web-cache:
@fluidframework/driver-web-cache: TypeError: Cannot read properties of undefined (reading 'kind')
@fluidframework/driver-web-cache: Occurred while linting D:\FluidFramework\packages\drivers\driver-web-cache\src\FluidCache.ts:257
@fluidframework/driver-web-cache: Rule: "@typescript-eslint/unbound-method"
@fluidframework/driver-web-cache:     at checkIfMethod (D:\FluidFramework\node_modules\.pnpm\@typescript-eslint+eslint-p_8b9c4a874c8369e3aeb983128d84ae5e\node_modules\@typescript-eslint\eslint-plugin\dist\rules\unbound-method.js:251:26)
@fluidframework/driver-web-cache:     at checkIfMethodAndReport (D:\FluidFramework\node_modules\.pnpm\@typescript-eslint+eslint-p_8b9c4a874c8369e3aeb983128d84ae5e\node_modules\@typescript-eslint\eslint-plugin\dist\rules\unbound-method.js:133:53)
@fluidframework/driver-web-cache:     at MemberExpression (D:\FluidFramework\node_modules\.pnpm\@typescript-eslint+eslint-p_8b9c4a874c8369e3aeb983128d84ae5e\node_modules\@typescript-eslint\eslint-plugin\dist\rules\unbound-method.js:173:17)
@fluidframework/driver-web-cache:     at ruleErrorHandler (D:\FluidFramework\node_modules\.pnpm\eslint@8.57.1\node_modules\eslint\lib\linter\linter.js:1076:28)
@fluidframework/driver-web-cache:     at D:\FluidFramework\node_modules\.pnpm\eslint@8.57.1\node_modules\eslint\lib\linter\safe-emitter.js:45:58
@fluidframework/driver-web-cache:     at Array.forEach (<anonymous>)
@fluidframework/driver-web-cache:     at Object.emit (D:\FluidFramework\node_modules\.pnpm\eslint@8.57.1\node_modules\eslint\lib\linter\safe-emitter.js:45:38)
@fluidframework/driver-web-cache:     at NodeEventGenerator.applySelector (D:\FluidFramework\node_modules\.pnpm\eslint@8.57.1\node_modules\eslint\lib\linter\node-event-generator.js:297:26)
@fluidframework/driver-web-cache:     at NodeEventGenerator.applySelectors (D:\FluidFramework\node_modules\.pnpm\eslint@8.57.1\node_modules\eslint\lib\linter\node-event-generator.js:326:22)
@fluidframework/driver-web-cache:     at NodeEventGenerator.enterNode (D:\FluidFramework\node_modules\.pnpm\eslint@8.57.1\node_modules\eslint\lib\linter\node-event-generator.js:340:14)

@github-actions github-actions bot added dependencies Pull requests that update a dependency file base: main PRs targeted against main branch labels Nov 5, 2025
@TommyBrosman TommyBrosman changed the title [Draft] Deduplicated pnpm dependencies Build: Fix for erroneous lint failure on @typescript-eslint/unbound-method rule Nov 5, 2025
@TommyBrosman TommyBrosman marked this pull request as ready for review November 5, 2025 22:04
Copilot AI review requested due to automatic review settings November 5, 2025 22:04
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.

Copilot wasn't able to review any files in this pull request.

Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

@CraigMacomber
Copy link
Contributor

CraigMacomber commented Nov 5, 2025

The error you are fixing can be fixed by deleting your node_modules and reinstalling. Making a PR that happens to make a change which causes some things to be reinstalled might happen to have fixed it for you as well, but I suspect it's not sure this error is less likely to occur with the lock file changes you are proposing.

That said, I think this is a good change, keeping things deduped is nice, but I think the claim for what it fixes in the description might not be accurate

@github-actions github-actions bot removed the dependencies Pull requests that update a dependency file label Nov 5, 2025
@alexvy86
Copy link
Contributor

alexvy86 commented Nov 5, 2025

The error you are fixing can be fixed by deleting your node_modules and reinstalling. Making a PR that happens to make a change which causes some things to be reinstalled might happen to have fixed it for you as well, but I suspect it's not sure this error is less likely to occur with the lock file changes you are proposing.

That said, I think this is a good change, keeping things deduped is nice, but I think the claim for what it fixes in the description might not be accurate

I think @TommyBrosman did try reinstalling after cleaning up node_modules and it didn't help; it does seem like a different issue from the one that manifests as eslint rules not being found that has been discussed in some other channels.

@TommyBrosman TommyBrosman enabled auto-merge (squash) November 5, 2025 22:50
@TommyBrosman
Copy link
Contributor Author

This issue was addressed by #25774.

auto-merge was automatically disabled November 5, 2025 23:00

Pull request was closed

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

Labels

base: main PRs targeted against main branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants