hashlips-lab / nft-erc721-collection

MIT License
446 stars 397 forks source link

Error #362

Closed Exper-t closed 2 years ago

Exper-t commented 2 years ago

After restarting 2 times on version 2.4.2 I have again got this error after entering "yarn verify"+contract address+" --network truffle"

This is the error I get: **"Error in plugin @nomiclabs/hardhat-etherscan: Invalid API Key

For more info 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."**

However I don't see what is wrong with my API key as it is made from the Etherscan.io website just as Hashlips did in this video: https://www.youtube.com/watch?v=Zhmj4PiJ-GA

at the time 50:50

Could someone please help me solve this.

Many Thanks

liarco commented 2 years ago

Hi @Exper-t, issues are for bug reports only (I have to close this as invalid since it misses all the required information that you deleted). Community support for questions can be found here.

Make sure you watch my video series about this project (especially ep.04 about configuration) because it goes more into details. I guess you may be using an Etherscan API while working on a different network like Polygon.

Exper-t commented 2 years ago

I am using the Ethereum.io api because I am deploying the contract first to the rinkby testnet then to the ethereum blockchain. I still don't know why it is saying my API key is invalid. Could you please help. Many thanks

mcbeav commented 2 years ago

I am having the same exact issue. Is there possibly a bug here? Instead of assuming it's user error, I have gone through the same steps. Using the same video series, I have followed the steps exactly, and I have tried this about 10 times now. I have tried new etherscan.io API keys, I tried replacing the ENV variables inside the hardhat config with the API key directly, but I get the same result of invalid API key everytime when attempting to verify, and it happens on all of the Ethereum test networks.

liarco commented 2 years ago

Hi @Exper-t and @mcbeav, I just checked the Etherscan status page and is seems like they are having issues with their API since a couple of days ago.

https://etherscan.freshstatus.io/

I guess we have to wait until that's solved before we can investigate any further.

Exper-t commented 2 years ago

Thank You very much liarco!

liarco commented 2 years ago

Thank You very much liarco!

You are welcome! If the problem persists even a few hours after their status is back ok, then please open a proper issue with all the required info in order to help me troubleshooting.

Thank you!

mcbeav commented 2 years ago

Thank you for the feedback, and checking into it! Appreciate the help!

mikemanila commented 2 years ago

Having the same issue as well and it has been 5 days now. Hope it gets sorted out soon!

Error in plugin @nomiclabs/hardhat-etherscan: Invalid API Key

For more info 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.

liarco commented 2 years ago

I'm temporarily reopening the issue so people can find it easily. Unfortunately Etherscan is still having issues with their API, that's pretty sad :(

locache commented 2 years ago

Having the same issue today.

mikemanila commented 2 years ago

Hoping this gets solved soon!

liarco commented 2 years ago

We are using the verification library from Hardhat, they got this error reported for the first time yesterday: https://github.com/NomicFoundation/hardhat/issues/2989

Etherscan's status page says the API should work again now. I didn't have the time to test this on my side yet.

Can anyone please try again?

Thank you.

Exper-t commented 2 years ago

I have tried again and still I am getting the same error of invalid api key despite Etherscan's status website insisting that the API services are operational.

locache commented 2 years ago

It just worked worked for me today! So its likely intermittent issues with Etherscan rinkeby test network

svensei commented 2 years ago

Yep the problem is solved finally, it was etherscan api problem -.-

liarco commented 2 years ago

Thanks everyone for the information. I'm gonna close this now since it looks like it has nothing to do with our code.

sardarahmedkhan505 commented 10 months ago

I am facing the issue : Error in plugin @nomicfoundation/hardhat-verify: Invalid API Key