FIL-Builders / onramp-contracts

Prototyping smart contracts piping data to the filecoin network
0 stars 0 forks source link

node dependency problems running hardhat compile #14

Closed snissn closed 1 day ago

snissn commented 1 day ago

trying to run npm run compile i am in "node dependency hell"

mikers@mikers-B560-DS3H-AC-Y1:~/dev/fil-builders/onramp-contracts$ npm run compile

> @onramp_contract/hardhat@0.0.1 compile
> npx hardhat compile

An unexpected error occurred:

Error: Cannot find module '@nomicfoundation/hardhat-toolbox'
Require stack:
- /home/mikers/dev/fil-builders/onramp-contracts/hardhat.config.ts
- /home/mikers/node_modules/hardhat/internal/core/config/config-loading.js
- /home/mikers/node_modules/hardhat/internal/cli/cli.js
- /home/mikers/node_modules/hardhat/internal/cli/bootstrap.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:1134:15)
    at Function.Module._resolveFilename.sharedData.moduleResolveFilenameHook.installedValue [as _resolveFilename] (/home/mikers/node_modules/@cspotcode/source-map-support/source-map-support.js:811:30)
    at Function.Module._load (node:internal/modules/cjs/loader:975:27)
    at Module.require (node:internal/modules/cjs/loader:1225:19)
    at require (node:internal/modules/helpers:177:18)
    at Object.<anonymous> (/home/mikers/dev/fil-builders/onramp-contracts/hardhat.config.ts:2:1)
    at Module._compile (node:internal/modules/cjs/loader:1356:14)
    at Module.m._compile (/home/mikers/node_modules/ts-node/src/index.ts:1618:23)
    at Module._extensions..js (node:internal/modules/cjs/loader:1414:10)
    at Object.require.extensions.<computed> [as .ts] (/home/mikers/node_modules/ts-node/src/index.ts:1621:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/home/mikers/dev/fil-builders/onramp-contracts/hardhat.config.ts',
    '/home/mikers/node_modules/hardhat/internal/core/config/config-loading.js',
    '/home/mikers/node_modules/hardhat/internal/cli/cli.js',
    '/home/mikers/node_modules/hardhat/internal/cli/bootstrap.js'
  ]
}
mikers@mikers-B560-DS3H-AC-Y1:~/dev/fil-builders/onramp-contracts$ yarn^C
mikers@mikers-B560-DS3H-AC-Y1:~/dev/fil-builders/onramp-contracts$ npm i
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR! 
npm ERR! While resolving: hardhat-deploy-ethers@0.4.2
npm ERR! Found: hardhat-deploy@0.11.45
npm ERR! node_modules/hardhat-deploy
npm ERR!   dev hardhat-deploy@"^0.11.45" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer hardhat-deploy@"^0.12.0" from hardhat-deploy-ethers@0.4.2
npm ERR! node_modules/hardhat-deploy-ethers
npm ERR!   dev hardhat-deploy-ethers@"^0.4.1" from the root project
npm ERR! 
npm ERR! Conflicting peer dependency: hardhat-deploy@0.12.4
npm ERR! node_modules/hardhat-deploy
npm ERR!   peer hardhat-deploy@"^0.12.0" from hardhat-deploy-ethers@0.4.2
npm ERR!   node_modules/hardhat-deploy-ethers
npm ERR!     dev hardhat-deploy-ethers@"^0.4.1" 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/mikers/.npm/_logs/2024-10-23T01_29_12_779Z-eresolve-report.txt

npm ERR! A complete log of this run can be found in: /home/mikers/.npm/_logs/2024-10-23T01_29_12_779Z-debug-0.log
mikers@mikers-B560-DS3H-AC-Y1:~/dev/fil-builders/onramp-contracts$ yarn
yarn install v1.22.21
warning package.json: No license field
warning ../../../package.json: No license field
info No lockfile found.
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
warning @onramp_contract/hardhat@0.0.1: No license field
[1/4] Resolving packages...
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > ethers > uuid@2.0.1: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/blockchain-utils@0.1.9: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/debug-utils@6.0.57: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/contract-schema@3.4.16: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/interface-adapter@0.5.37: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/error@0.1.1: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > @ensdomains/ens@0.4.5: Please use @ensdomains/ens-contracts
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > @ensdomains/resolver@0.2.4: Please use @ensdomains/ens-contracts
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/debug-utils > @truffle/codec@0.17.3: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > content-hash > cids@0.7.5: This module has been superseded by the multiformats module
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > content-hash > multicodec@0.5.7: This module has been superseded by the multiformats module
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > content-hash > cids > multicodec@1.0.4: This module has been superseded by the multiformats module
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > @ensdomains/ens > testrpc@0.0.1: testrpc has been renamed to ganache-cli, please use this package from now on.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/debug-utils > @truffle/codec > @truffle/abi-utils@1.0.3: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/debug-utils > @truffle/codec > @truffle/compile-common@0.9.8: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @truffle/debug-utils > @truffle/codec > @truffle/compile-common > @truffle/error@0.2.2: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > content-hash > cids > multibase@0.6.1: This module has been superseded by the multiformats module
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > content-hash > multihashes > multibase@0.7.0: This module has been superseded by the multiformats module
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > @ensdomains/ens > solc > fs-extra > rimraf@2.7.1: Rimraf versions prior to v4 are no longer supported
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > ethereum-ens > web3 > web3-bzz > swarm-js > mkdirp-promise@5.0.1: This package is broken and no longer maintained. 'mkdirp' itself supports promises now, please switch to that.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > @ensdomains/ens > solc > fs-extra > rimraf > glob@7.2.3: Glob versions prior to v9 are no longer supported
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > @ensdomains/ensjs > @ensdomains/ens > solc > fs-extra > rimraf > glob > inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > ethereum-ens > web3 > web3-bzz > swarm-js > eth-lib > servify > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > ethereum-ens > web3 > web3-bzz > swarm-js > eth-lib > servify > request > uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
warning filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract > ethereum-ens > web3 > web3-bzz > swarm-js > eth-lib > servify > request > har-validator@5.1.5: this library is no longer supported
warning hardhat > glob@7.2.0: Glob versions prior to v9 are no longer supported
warning hardhat > glob > inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
warning hardhat > mocha > glob@8.1.0: Glob versions prior to v9 are no longer supported
warning hardhat > mocha > glob > inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
warning hardhat-deploy > zksync-web3@0.14.4: This package has been deprecated in favor of zksync-ethers@5.0.0
warning typechain > glob@7.1.7: Glob versions prior to v9 are no longer supported
warning typechain > glob > inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
[2/4] Fetching packages...
[3/4] Linking dependencies...
warning " > ts-node@10.9.2" has unmet peer dependency "@types/node@*".
warning " > ts-node@10.9.2" has unmet peer dependency "typescript@>=2.7".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "@nomicfoundation/hardhat-chai-matchers@^2.0.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "@nomicfoundation/hardhat-ignition-ethers@^0.15.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "@nomicfoundation/hardhat-network-helpers@^1.0.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "@nomicfoundation/hardhat-verify@^2.0.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "@types/chai@^4.2.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "@types/mocha@>=9.1.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "@types/node@>=18.0.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "chai@^4.2.0".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "hardhat-gas-reporter@^1.0.8".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "solidity-coverage@^0.8.1".
warning " > @nomicfoundation/hardhat-toolbox@5.0.0" has unmet peer dependency "typescript@>=4.5.0".
warning " > @typechain/ethers-v6@0.5.1" has unmet peer dependency "typescript@>=4.7.0".
warning "@typechain/ethers-v6 > ts-essentials@7.0.3" has unmet peer dependency "typescript@>=3.7.0".
warning "filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5@2.0.7" has unmet peer dependency "@nomiclabs/hardhat-web3@^2.0.0".
warning "filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5@2.0.7" has unmet peer dependency "web3@^1.0.0-beta.36".
warning "filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract@4.5.10" has unmet peer dependency "web3@^1.2.1".
warning "filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract@4.5.10" has unmet peer dependency "web3-core-helpers@^1.2.1".
warning "filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract@4.5.10" has unmet peer dependency "web3-core-promievent@^1.2.1".
warning "filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract@4.5.10" has unmet peer dependency "web3-eth-abi@^1.2.1".
warning "filecoin-solidity-api > solidity-cborutils > @ensdomains/buffer > @nomiclabs/hardhat-truffle5 > @nomiclabs/truffle-contract@4.5.10" has unmet peer dependency "web3-utils@^1.2.1".
warning " > hardhat-deploy-ethers@0.4.2" has incorrect peer dependency "hardhat-deploy@^0.12.0".
warning " > typechain@8.3.2" has unmet peer dependency "typescript@>=4.3.0".
[4/4] Building fresh packages...
success Saved lockfile.
warning Your current version of Yarn is out of date. The latest version is "1.22.22", while you're on "1.22.21".
info To upgrade, run the following command:
$ curl --compressed -o- -L https://yarnpkg.com/install.sh | bash
Done in 21.04s.
mikers@mikers-B560-DS3H-AC-Y1:~/dev/fil-builders/onramp-contracts$ npm run compile

> @onramp_contract/hardhat@0.0.1 compile
> npx hardhat compile

Error HH801: Plugin @nomicfoundation/hardhat-toolbox requires the following dependencies to be installed: @nomicfoundation/hardhat-chai-matchers, @nomicfoundation/hardhat-ignition-ethers, @nomicfoundation/hardhat-network-helpers, @nomicfoundation/hardhat-verify, @types/mocha, hardhat-gas-reporter, solidity-coverage.
Please run: npm install --save-dev "@nomicfoundation/hardhat-chai-matchers@^2.0.0" "@nomicfoundation/hardhat-ignition-ethers@^0.15.0" "@nomicfoundation/hardhat-network-helpers@^1.0.0" "@nomicfoundation/hardhat-verify@^2.0.0" "@types/mocha@>=9.1.0" "hardhat-gas-reporter@^1.0.8" "solidity-coverage@^0.8.1"

For more info go to https://hardhat.org/HH801 or run Hardhat with --show-stack-traces
mikers@mikers-B560-DS3H-AC-Y1:~/dev/fil-builders/onramp-contracts$ yarn run compile
yarn run v1.22.21
warning package.json: No license field
warning ../../../package.json: No license field
$ npx hardhat compile
Error HH801: Plugin @nomicfoundation/hardhat-toolbox requires the following dependencies to be installed: @nomicfoundation/hardhat-chai-matchers, @nomicfoundation/hardhat-ignition-ethers, @nomicfoundation/hardhat-network-helpers, @nomicfoundation/hardhat-verify, @types/mocha, hardhat-gas-reporter, solidity-coverage.
Please run: npm install --save-dev "@nomicfoundation/hardhat-chai-matchers@^2.0.0" "@nomicfoundation/hardhat-ignition-ethers@^0.15.0" "@nomicfoundation/hardhat-network-helpers@^1.0.0" "@nomicfoundation/hardhat-verify@^2.0.0" "@types/mocha@>=9.1.0" "hardhat-gas-reporter@^1.0.8" "solidity-coverage@^0.8.1"

For more info go to https://hardhat.org/HH801 or run Hardhat with --show-stack-traces
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
mikers@mikers-B560-DS3H-AC-Y1:~/dev/fil-builders/onramp-contracts$ npm install --save-dev "@nomicfoundation/hardhat-chai-matchers@^2.0.0" "@nomicfoundation/hardhat-ignition-ethers@^0.15.0" "@nomicfoundation/hardhat-network-helpers@^1.0.0" "@nomicfoundation/hardhat-verify@^2.0.0" "@types/mocha@>=9.1.0" "hardhat-gas-reporter@^1.0.8" "solidity-coverage@^0.8.1"
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR! 
npm ERR! While resolving: hardhat-deploy-ethers@0.4.2
npm ERR! Found: hardhat-deploy@0.11.45
npm ERR! node_modules/hardhat-deploy
npm ERR!   dev hardhat-deploy@"^0.11.45" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer hardhat-deploy@"^0.12.0" from hardhat-deploy-ethers@0.4.2
npm ERR! node_modules/hardhat-deploy-ethers
npm ERR!   dev hardhat-deploy-ethers@"^0.4.1" from the root project
npm ERR! 
npm ERR! Conflicting peer dependency: hardhat-deploy@0.12.4
npm ERR! node_modules/hardhat-deploy
npm ERR!   peer hardhat-deploy@"^0.12.0" from hardhat-deploy-ethers@0.4.2
npm ERR!   node_modules/hardhat-deploy-ethers
npm ERR!     dev hardhat-deploy-ethers@"^0.4.1" 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/mikers/.npm/_logs/2024-10-23T01_34_41_871Z-eresolve-report.txt

npm ERR! A complete log of this run can be found in: /home/mikers/.npm/_logs/2024-10-23T01_34_41_871Z-debug-0.log
snissn commented 1 day ago

fixed 33e481d

npm install --save-dev hardhat-deploy@^0.12.0