A guide on manual verifications #17
Closed
defido
started this conversation in
Show and tell
Replies: 1 comment 5 replies
-
Thanks for sharing your input @defido! My recommendation is usually the same in case the API-based verification fails: try using the flattened contract file. As mentioned correctly by you, currently the |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Still in testing mode...... Fantom scan presenting real issues in general verifying with constructor inputs. Unrelated to the starter. The below is just an idea/guide.
Just an idea to add an empty 'flatten' folder, then forge can flatten the contract for manual verifications. It seems forge strips the
//SPDX-License-Identifier:
automatically. As verification via the API is often sketchy, people knowing this idea, removes the need to search. Or it can be left as an 'IDEA' and people can see how I fixed my verification issues, and it might help them too.This did multiple greatly positive things for me:
//SPDX-License-Identifier:
identifiersFirst make sure you have done your compiling using xDeployer to the on chain factory create2deployer
Then:
forge flatten --output flatten/Greeter.flattened.sol contracts/Greeter.sol
forge flatten --output <OUTPUT_DIRECTORY_FILE_NAME> <CONTRACT_LOCATION_CONTRACT_NAME.sol>
You might think of a better folder output? Without a folder it just spurts the file into the main folder.
Fill out the exact same parameters used in your projects version, license, choose 'single file', remember to turn on optimisation if you do optimisation runs, you can find this in the
hardhat.config.ts
file. Input your constructor arguments, often these are picked up automatically, find the ABI in theabis
folder and match it to your contract name, in this caseGreeter.sol
.Beta Was this translation helpful? Give feedback.
All reactions