Skip to content

Lesson 7 npx hardhat deploy --tags mocks returns Nothing to compile #591

Answered by bwz123
engrusmanbelloa asked this question in Q&A
Discussion options

You must be logged in to vote

There are three problems in your code

  1. you define {developmentChains} in helper-hardhat-config.js
export default {
    networkConfig,
    developmentChains,
    DECIMALS,
    INITIAL_ANSWER
}

but you use it as { deploymentChains } in your 00-deploy-mocks.js

const {
    deploymentChains,
    DECIMALS,
    INITIAL_ANSWER
} = require("../helper-hardhat-config")

and there

 if (deploymentChains.includes(network.name)) {}
  1. it is MockV3Aggregator not MockV3Aggrigator, check your code again
await deploy("MockV3Aggregator", {
            contract: "MockV3Aggregator",
            from: deployer,
            log: true,
            args: [DECIMALS, INITIAL_ANSWER],
        }
  1. it's "module.expor…

Replies: 3 comments 9 replies

Comment options

You must be logged in to vote
1 reply
@alymurtazamemon
Comment options

Answer selected by alymurtazamemon
Comment options

You must be logged in to vote
4 replies
@engrusmanbelloa
Comment options

@engrusmanbelloa
Comment options

@bwz123
Comment options

@engrusmanbelloa
Comment options

Comment options

You must be logged in to vote
4 replies
@engrusmanbelloa
Comment options

@Maakai123
Comment options

@benjbright
Comment options

@nsawit
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
7 participants