LESSON 07 | Error HH604: Error running JSON-RPC server: #4782
Answered
by
alymurtazamemon
Umairulislam
asked this question in
Q&A
-
I'm running the following command
looks like the local host is not working
This is my 00-deploy-mocks.js code const { network } = require("hardhat")
const { developmentChains, decimals, initialAnswer } = require("../helper-hardhat-config")
module.exports = async ({ getNamedAccounts, deployments }) => {
const { deploy, log } = deployments
const { deployer } = await getNamedAccounts()
// const chainId = network.config.chainId
if (developmentChains.includes(network.name)) {
log("Local network detected! Deploying mocks...")
await deploy("MockV3Aggregator", {
contract: "MockV3Aggregator",
from: deployer,
log: true,
args: [decimals, initialAnswer],
})
log("Mocks deployed!")
log("--------------------------------------------")
}
}
module.exports.tags = ["all", "mocks"] |
Beta Was this translation helpful? Give feedback.
Answered by
alymurtazamemon
Feb 10, 2023
Replies: 1 comment 1 reply
-
@Umairulislam Make sure to first clean the artifacts and regenerate them with these commands; npx hardhat clean npx hardhat compile Try this and see does this resolve the issue. |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
Umairulislam
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@Umairulislam Make sure to first clean the artifacts and regenerate them with these commands;
Try this and see does this resolve the issue.