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

Dependency Conflit - 2024-10-28 #14

Open
snustorm opened this issue Oct 28, 2024 · 0 comments
Open

Dependency Conflit - 2024-10-28 #14

snustorm opened this issue Oct 28, 2024 · 0 comments

Comments

@snustorm
Copy link

Have meet some dependency conflict issue when npm install the following dependencies:

{
"name": "@token-vesting/anchor",
"version": "0.0.1",
"dependencies": {
"@coral-xyz/anchor": "^0.30.0",
"@solana/spl-token": "^0.4.8",
"@solana/web3.js": "1.94.0",
"anchor-bankrun": "^0.4.0",
"solana-bankrun": "^0.2.0",
"spl-token-bankrun": "0.2.5"
},
"main": "./index.cjs",
"module": "./index.js",
"private": true
}

Errors:

npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving: @solana/[email protected]
npm error Found: @solana/[email protected]
npm error node_modules/@solana/web3.js
npm error @solana/web3.js@"1.94.0" from the root project
npm error @solana/web3.js@"^1.68.0" from @coral-xyz/[email protected]
npm error node_modules/@coral-xyz/anchor
npm error @coral-xyz/anchor@"^0.30.0" from the root project
npm error peer @coral-xyz/anchor@"^0.30.0" from [email protected]
npm error node_modules/anchor-bankrun
npm error anchor-bankrun@"^0.4.0" from the root project
npm error 5 more (@coral-xyz/borsh, @solana/buffer-layout-utils, ...)
npm error
npm error Could not resolve dependency:
npm error peer @solana/web3.js@"^1.95.3" from @solana/[email protected]
npm error node_modules/@solana/spl-token
npm error @solana/spl-token@"^0.4.8" from the root project
npm error
npm error Conflicting peer dependency: @solana/[email protected]
npm error node_modules/@solana/web3.js
npm error peer @solana/web3.js@"^1.95.3" from @solana/[email protected]
npm error node_modules/@solana/spl-token
npm error @solana/spl-token@"^0.4.8" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.
npm error
npm error
npm error For a full report see:
npm error /Users/chester/.npm/_logs/2024-10-28T08_12_47_978Z-eresolve-report.txt
npm error A complete log of this run can be found in: /Users/chester/.npm/_logs/2024-10-28T08_12_47_978Z-debug-0.log

the issue can be solved by just run :npm install --legacy-peer-deps (ignore the conflicts), but i want to know how to solve this dependency conflict issue or how to find the compatible version at this point of time, thanks

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

1 participant