Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: ESLint config cli fails - eslint@9.3.0 vs 8.56.0 #120

Closed
1 task done
diberry opened this issue May 21, 2024 · 1 comment · Fixed by #118
Closed
1 task done

Bug: ESLint config cli fails - eslint@9.3.0 vs 8.56.0 #120

diberry opened this issue May 21, 2024 · 1 comment · Fixed by #118
Labels
accepted bug Something isn't working

Comments

@diberry
Copy link

diberry commented May 21, 2024

Environment

Node version: v20.13.1
npm version: 10.5.2
Local ESLint version:
Global ESLint version:
Operating System: mcr.microsoft.com/devcontainers/typescript-node:1-20-bookworm

What parser are you using?

Other

What did you do?

Configuration
npm init @eslint/config@latest -- --debug
<!-- Paste your code here -->

What did you expect to happen?

Create config file and install dependencies.

What actually happened?

✔ How would you like to use ESLint? · problems
✔ What type of modules does your project use? · commonjs
✔ Which framework does your project use? · none
✔ Does your project use TypeScript? · typescript
✔ Where does your code run? · browser
The config that you've selected requires the following dependencies:

eslint@9.x, globals, @eslint/js, typescript-eslint
✔ Would you like to install them now? · No / Yes
✔ Which package manager do you want to use? · npm
☕️Installing...
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: ts-common@1.0.0
npm ERR! Found: eslint@9.3.0
npm ERR! node_modules/eslint
npm ERR! dev eslint@"9.x" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer eslint@"^8.56.0" from typescript-eslint@7.10.0
npm ERR! node_modules/typescript-eslint
npm ERR! dev typescript-eslint@"*" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR!
npm ERR! For a full report see:
npm ERR! /home/node/.npm/_logs/2024-05-21T20_57_05_935Z-eresolve-report.txt

npm ERR! A complete log of this run can be found in: /home/node/.npm/_logs/2024-05-21T20_57_05_935Z-debug-0.log
A config file was generated, but the config file itself may not follow your linting rules.

Link to Minimal Reproducible Example

https://github.com/diberry/eslint9-examples/tree/diberry/feature-examples/ts-common

Participation

  • I am willing to submit a pull request for this issue.

Additional comments

The config file was created.

@diberry
Copy link
Author

diberry commented May 23, 2024

Temporary fix:

  "devDependencies": {
    "@eslint/js": "^9.3.0",
    "@types/node": "^20.12.12",
    "eslint": "^9.3.0",
    "globals": "^15.3.0",
    "typescript": "^5.4.5",
    "typescript-eslint": "^8.0.0-alpha.10"
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted bug Something isn't working
Projects
Status: Complete
2 participants