Open ClementWalter opened 2 years ago
Maybe it's the same error as in https://github.com/wighawag/hardhat-deploy/issues/253
Hey there!
I'm experiencing the same issue with both etherscan-verify
from hardhat-deploy and hardhat-etherscan
on the Polygon Mumbai network:
contract XXX failed to submit : "NOTOK" : "Unable to process the standard-input-json you uploaded" [object Object]
.
I also tried manually on the Source Code Verfication Submission API without success.
However Sourcify
does work.
@RomualdH does it work with hardhat verify address args
like the OP here ?
if not, it might be an issue with polygonscan.
Please provide more details
The annoying thing about etherscan is that we are dealing with a black box. Might be worth contacting them too
@RomualdH does it work with
hardhat verify address args
like the OP here ?
Doesn't work with hh verify --network POLYGON_test --constructor-args arguments.js MY_CONTRACT_ADDRESS
.
Will send an email to PolygonScan team.
gm all, will be joining in this thread from Etherscan.
@RomualdH do you have a Solidity Json Input gist we can try to reproduce with the verify demo page ?
@RomualdH do you have a Solidity Json Input gist we can try to reproduce with the verify demo page ?
Please find attached the file used when verifying the contract Bank:
Thanks for the contract address and Json Input, we are able to reproduce the error message on our end too.
It does not exceed the upload size limit of 3MB, eyeballing the JSON formatting looks fine too.
@RomualdH would you be able to attach a repo for the original source files as well ?
@RomualdH would you be able to attach a repo for the original source files as well ?
Sure, it has been verified on Sourcify: https://repo.sourcify.dev/contracts/full_match/80001/0x35fd0516074d4735FEA7Ee7eDC69176B2CfCB42a/sources/contracts/bank/
Hi @0xV4L3NT1N3 I deployed new contracts, the source code is here, but impossible to verify the Bank, Dice, CoinToss, Referral on PolygonScan Mumbai. We target a mainnet launch in less than 10 days. Hope this will not happen on mainnet...
Thank you in advance!
Thanks for the additional deployed contracts and source, tried them on my end and I seem to getting very different bytecode comparisons.
Could you verify that your contracts were compiled using solc 0.8.11
with no optimization enabled as per the Hardhat config file ?
Could you verify that your contracts were compiled using
solc 0.8.11
with no optimization enabled as per the Hardhat config file ?
The verification is working when setting the optimizer runs to a lower number. Thanks!
I'm also struggling with this issue. Verifies fine on Sourcify. Disabling optimization doesn't help. I've tried with a bunch of different solidity versions with no luck. Any ideas?
What is the approximate maximum number of runs allowed when verifying? Does anyone know? @RomualdH
What is the approximate maximum number of runs allowed when verifying? Does anyone know? @RomualdH
It's 100000000
Describe the bug
The
etherscan-verify
task fails with or without the--solc-input
flag but usinghardhat verify address args
with the address and args found in thedeployments/rinkeby
does work.To Reproduce
Contract is here: https://rinkeby.etherscan.io/address/0x6FA9f768110182eebB4fD086074C5b460BFE103E
This is the error message:
Using hardhat-etherscan I am able to verify:
versions hardhat-deploy [e.g. 0.9.14] : 0.9.24 hardhat : 2.8.0 nodejs : v17.3.0 @nomiclabs/hardhat-etherscan : 2.1.8
Additional context