rushstack icon indicating copy to clipboard operation
rushstack copied to clipboard

[eslint-config] Support for eslint-config-next

Open Michahide opened this issue 6 months ago • 2 comments

Summary

I'm trying to run pnpm dlx eslint --fix with my eslint package as follow:

  • eslint-plugin-unicorn
  • eslint-config-next
  • typescript-eslint

Repro steps

Expected result: I'm expecting the fix would run

Actual result:

Error: Cannot read config file: D:\next_project\node_modules.pnpm\[email protected]_e_bb04fd41856dce36426d8f084dc159a5\node_modules\eslint-config-next\index.js Error: Failed to patch ESLint because the calling module was not recognized. If you are using a newer ESLint version that may be unsupported, please create a GitHub issue: https://github.com/microsoft/rushstack/issues Referenced from: at Object. (D:\next_project\node_modules.pnpm@[email protected]\node_modules@rushstack\eslint-patch\lib_patch-base.js:167:19) at Module._compile (node:internal/modules/cjs/loader:1554:14) at Object..js (node:internal/modules/cjs/loader:1706:10) at Module.load (node:internal/modules/cjs/loader:1289:32) at Function._load (node:internal/modules/cjs/loader:1108:12) at TracingChannel.traceSync (node:diagnostics_channel:322:14) at wrapModuleLoad (node:internal/modules/cjs/loader:220:24) at Module.require (node:internal/modules/cjs/loader:1311:12) at require (node:internal/modules/helpers:136:16) at Object. (D:\next_project\node_modules.pnpm@[email protected]\node_modules@rushstack\eslint-patch\lib\modern-module-resolution.js:11:23)

Details

Standard questions

Please answer these questions to help us investigate your issue more quickly:

Question Answer
@rushstack/eslint-config version? 15.3.1
Operating system? Windows
Would you consider contributing a PR? No
TypeScript compiler version? 5.8.3
Node.js version (node -v)? 22.14.0

Michahide avatar May 06 '25 07:05 Michahide

We should add a feature to log the path of colling modules when we emit this error.

This may be addressed by https://github.com/microsoft/rushstack/pull/5219

iclanton avatar May 07 '25 18:05 iclanton

Seems to be a duplicate of #4965

WikiRik avatar May 29 '25 20:05 WikiRik