* Invalid value undefined for HardhatConfig.networks.rinkeby.url - Expected a value of type string. #319
-
When I try to run
And here is my
|
Beta Was this translation helpful? Give feedback.
Replies: 6 comments 15 replies
-
@rileymross You just have to take the URL from the Alchemy dashboard and private key from the meta mask. Replace RPC_URL and PRIVATE KEY with the above things inside .env |
Beta Was this translation helpful? Give feedback.
-
From my understanding, hardhat isn't using your metamask to deploy the contract. It uses an RPC to connect to the blockchain and your private_key/nmenonic to sign transactions. If you want to add alchemy to your metamask to interact with a GUI front_end, click the network dropdown, then hit "add network" and enter the information for the chain you want to connect to providing your "alchemy RPC url" |
Beta Was this translation helpful? Give feedback.
-
I changed the question because I realized it didn't have to do with alchemy or metamask. it's something with the config file. |
Beta Was this translation helpful? Give feedback.
-
https://hardhat.org/config#available-config-options I think there's a typo with
|
Beta Was this translation helpful? Give feedback.
-
I figured it out on my own. I was supposed to put quotation marks around the |
Beta Was this translation helpful? Give feedback.
-
@rileymross Glad you figured it out |
Beta Was this translation helpful? Give feedback.
I figured it out on my own. I was supposed to put quotation marks around the
RINKEBY_RPC_URL
Also, you only need to make
account
plural if you have mutiple private keys in that line.However, moving along I realized its better to simply put
procces.env.[ENV information]
This question ended up having some people answering it but the questions/answers became unclear along the way. @mattjaf @gmluqa and @ali-thegilfoyle still knew what they were talking about.