eslint-plugin-import: Cannot find module eslint-module-utils/visit after updating to v2.25.1
I had previously eslint-plugin-import@2.24.2
. When updating to v2.25.1
, I’m getting the following error:
Syntax Error: Thread Loader (Worker 0)
Failed to load plugin 'import' declared in '.eslintrc.json': Cannot find module 'eslint-module-utils/visit'
Require stack:
- /code/node_modules/eslint-plugin-import/lib/ExportMap.js
- /code/node_modules/eslint-plugin-import/lib/rules/named.js
- /code/node_modules/eslint-plugin-import/lib/index.js
- /code/node_modules/@eslint/eslintrc/lib/config-array-factory.js
- /code/node_modules/@eslint/eslintrc/lib/index.js
- /code/node_modules/eslint/lib/cli-engine/cli-engine.js
- /code/node_modules/eslint/lib/cli-engine/index.js
- /code/node_modules/eslint/lib/api.js
- /code/node_modules/eslint-loader/index.js
- /code/node_modules/loader-runner/lib/loadLoader.js
- /code/node_modules/loader-runner/lib/LoaderRunner.js
- /code/node_modules/thread-loader/dist/worker.js
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 44
- Comments: 23 (12 by maintainers)
Commits related to this issue
- chore(deps-dev): bump deps Bump dev dependencies. Bump eslint-plugin-import later when https://github.com/import-js/eslint-plugin-import/issues/2255 has been resolved. — committed to Haprog/hash-actions by Haprog 3 years ago
- Downgrade eslint and eslint-plugin-import This fixes an issue related to: https://github.com/import-js/eslint-plugin-import/issues/2255 — committed to mozilla/glean.js by brizental 3 years ago
- deps: revert eslint-plugin-import@2.24.2 Due to https://github.com/import-js/eslint-plugin-import/issues/2255 — committed to raiden-network/light-client by andrevmatos 3 years ago
- deps: revert eslint-plugin-import@2.24.2 Due to https://github.com/import-js/eslint-plugin-import/issues/2255 — committed to raiden-network/light-client by andrevmatos 3 years ago
- deps: revert eslint-plugin-import@2.24.2 Due to https://github.com/import-js/eslint-plugin-import/issues/2255 — committed to raiden-network/light-client by andrevmatos 3 years ago
- deps: revert eslint-plugin-import@2.24.2 Due to https://github.com/import-js/eslint-plugin-import/issues/2255 — committed to raiden-network/light-client by andrevmatos 3 years ago
https://github.com/import-js/eslint-plugin-import/pull/2257
v2.25.2 is published.
@ljharb Allright then I will close my PR, because I don’t know how I can fix this issue 😃
I have updated
^2.6.2
to~2.7.0
in my PR (#2257) , so I think 2.6.2 won’t be valid in any lockfile now. I think the problem with^2.7.0
is, that2.6.2
is still a valid version.I’m using yarn, adding
yarn add -D eslint-module-utils
fixing the crashing vscode extension host, but now I’m seeingCannot read property 'body' of undefined Occurred while linting file..
errors in vscode problem Eslint output. PS I’m using eslint 7.32.0, cos updating to 8 has issues with eslint-plugin-next, and I guess multiple other plugins, but nextjs is crashing extension host first.reverting back to 2.24.2 fixes an issue.