Hi, I am trying to verify my transparent proxy contract. I successfully verified the implementation contract. But having problems when trying to verify the proxy. I use create3factory to deploy the contracts. I am getting this error:
Failed to verify TransparentUpgradeableProxy contract at 0x4b17F5Ef7F6CcdD06105F0a260c0E39eC6376007: Bytecode does not match with the current version of TransparentUpgradeableProxy in the Hardhat Upgrades plugin.
Failed to verify directly using hardhat verify: The address provided as argument contains a contract, but its bytecode doesn't match any of your local contracts.
Since your proxy is deployed as your custom TransparentProxy contract, you would need to verify it manually, because its bytecode is different from what the Hardhat plugin normally deploys. See How to verify a contract on Etherscan/BscScan/PolygonScan for general info on verification.
Note: your pattern to use Ownable within the proxy itself is not recommended, because that risks storage clash and possible function selector clashes with the implementation. See https://docs.openzeppelin.com/upgrades-plugins/1.x/proxies. Instead, consider using OwnableUpgradeable in your implementation instead.
yes, I read this one but still having problems with verifying. I upload solc-input.json and I am getting this error : Error! Invalid constructor arguments provided. Please verify that they are in ABI-encoded format
here is my abi encode data :
0x0000000000000000000000007ab7de8ef151a3fb56d3440022dcd5856ab1820100000000000000000000000043d730dcbec77b1d5581a77642812f28b2088d10000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a490482d7200000000000000000000000000000000000000000000000000000000000000600000000000000000000000009bcd5003715c936051abd41e00b175b1756c2d90000000000000000000000000982aec3767cd5c31a66db55614da5f52c7b893e50000000000000000000000000000000000000000000000000000000000000001000000000000000000000000bb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c00000000000000000000000000000000000000000000000000000000
Right, I got it from Ethereum. What you provided earlier looks right for your bsc deployment.
I don't think I can help further as this really depends on how you compiled and deployed it. Just ensure that your solc JSON input contains your proxy contract which you deployed, and that your compiler version for Etherscan verification matches what you used to compile the proxy contract.