Skip to content

Cannot install [email protected] due to peer dependency issues #10447

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

Open
kgetz-arista opened this issue May 13, 2025 · 3 comments
Open

Cannot install [email protected] due to peer dependency issues #10447

kgetz-arista opened this issue May 13, 2025 · 3 comments

Comments

@kgetz-arista
Copy link

I've tried for several weeks, but the latest version of swagger-ui-react will not install due to peer dependency issues:

../../apps/storybook-app
└─┬ swagger-ui-react 5.21.0
  └─┬ swagger-client 3.35.0
    └─┬ @swagger-api/apidom-reference 1.0.0-beta.37
      └─┬ @swagger-api/apidom-parser-adapter-arazzo-json-1 1.0.0-beta.37
        └─┬ @swagger-api/apidom-parser-adapter-json 1.0.0-beta.37
          └─┬ tree-sitter-json 0.24.8
            └── ✕ unmet peer tree-sitter@^0.21.1: found 0.22.1 in @swagger-api/apidom-parser-adapter-json

This is in a Rush monorepo, and I've tried running rush update --full, which will update all indirect dependencies to their latest versions, but it still doesn't work. I don't have any tree-sitter package as a dependency, so this problem seems to be an issue with the Swagger stack of dependencies (and not anything on my end).

@dnoishi
Copy link

dnoishi commented May 16, 2025

Try installing it like this: npm i swagger-ui-react --legacy-peer-deps

@NguyenKyThinh94
Copy link

From npm v7 onwards, npm changed the way it handles peerDependencies:
Previously (in npm v6 and earlier), peerDependencies would only show a warning if they were missing.
But starting from npm v7, peerDependencies are automatically installed and must be compatible with the version requirements of the related packages.

@kaiyoma
Copy link

kaiyoma commented May 27, 2025

I'm not using npm. I'm using Rush with pnpm. But are you saying that I must install an exact version of tree-sitter in order to install Swagger now?

(Sorry for the confusion - I'm the OP but I was logged into a different account when I created this issue.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants