NomicFoundation / hardhat

Hardhat is a development environment to compile, deploy, test, and debug your Ethereum software.
https://hardhat.org
Other
7.12k stars 1.36k forks source link

Plugin @nomicfoundation/hardhat-ignition-ethers requires the following dependencies #5520

Open Asad45AsRa opened 1 month ago

Asad45AsRa commented 1 month ago

Version of Hardhat

Hardhat version 2.9.9

What happened?

F:\BlockChain World\LearningFold4\hardhat>npx hardhat help Error HH801: Plugin @nomicfoundation/hardhat-ignition-ethers requires the following dependencies to be installed: @nomicfoundation/hardhat-ignition, @nomicfoundation/ignition-core. Please run: npm install --save-dev "@nomicfoundation/hardhat-ignition@^0.15.0" "@nomicfoundation/ignition-core@^0.15.0"

Minimal reproduction steps

plese resolve that ![Uploading Screenshot (515).png…]()

Search terms

No response

kanej commented 1 month ago

Hey @Asad45AsRa, can you give us more context here, are you trying to install @nomicfoundation/hardhat-ignition?

Or is it that you are trying to update the toolbox?

sebastiantf commented 3 weeks ago

Seeing this as well when trying to install the latest toolbox following the docs

@kanej I'm using yarn

kanej commented 3 weeks ago

Seeing this as well when trying to install the latest toolbox following the docs

What package manager are you using? Is this npm/yarn/pnpm?

sebastiantf commented 3 weeks ago

updated original comment

kanej commented 2 weeks ago

updated original comment

yarn doesn't automatically install peer dependencies as npm does. The equivalent install for yarn for the @nomicfoundation/hardhat-toolbox toolbox would be:

yarn add --dev @nomicfoundation/hardhat-toolbox @nomicfoundation/hardhat-ignition @nomicfoundation/hardhat-ignition-ethers @nomicfoundation/hardhat-network-helpers @nomicfoundation/hardhat-chai-matchers @nomicfoundation/hardhat-ethers @nomicfoundation/hardhat-verify chai@4 ethers hardhat-gas-reporter solidity-coverage @typechain/hardhat typechain @typechain/ethers-v6
sebastiantf commented 2 weeks ago

But I used the same yarn command on the docs that also includes the long list incl peer deps

kanej commented 2 weeks ago

But I used the same yarn command on the docs that also includes the long list incl peer deps

I have done a run through locally on a new Hardhat project, installed via yarn and with then installed @nomicfoundation/hardhat-toolbox with the command above. I didn't see an error message - it installed cleanly.

What error message are you seeing?

sebastiantf commented 2 weeks ago

Oh yeah a fresh new hardhat project worked. I was trying to run the install command / upgrade deps in an existing hardhat project. I did try removing node_modules and lockfile. Still same.

In the end, ended up generating a new HH project and copying over the deps list in package.json