-
Notifications
You must be signed in to change notification settings - Fork 114
Add support for Blockscout #1313
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
|
The error in the second step is i.e. the concatenation of all the solidity files is too big to be posted to the API (no idea who's enforcing that limit, though). |
|
Suggestion is to try and validate contracts through the Blockscout UI directly |
Well, to start there and if that works then potentially write our own script to validate automatically in a more judicious way than the plugin tries to. |
|
For anyone else testing this, if you run the run in the directory with the docker files will cause them to only restart on failure. |
|
This is a lot lighter weight, and supports at least some of what we want... maybe it does enough? I did have to edit it to ignore warnings when verifying a contract |
|
Noting that the Standard JSON Input for a contract build can be pulled out of Hardhat via: |
1daef28 to
f753f74
Compare
|
Testing for contract-level verification, using the dependency contract at
Was able to verify this contract, under the @area any idea why we're compiling for paris? I don't see that as an explicit setting in our hardhat config. |
It's the hardhat default. The setting is conservative to stop people accidentally deploying contracts compiled to chains that they do not run on, as adding new opcodes to chains requires a hardfork and happens slowly. CreateX, for example, is only compiled for Paris. |
064b8d4 to
f251da1
Compare
f251da1 to
307a0ef
Compare
062b714 to
5ebc8fa
Compare
|
Currently working on isolating the various contract subdirectories so we can iteratively compile and verify the contracts without hitting the file upload limit. The following subdirectories have been isolated (can compile repo without them):
|
5ebc8fa to
3ec85b0
Compare



Closes #1286
Instructions:
Starting Blockscout (1 tab)
blockscout/docker-composeand rundocker compose -f hardhat-network.yml up(-dto daemonize)Blockscout will start running on
localhost:80by defaultStarting Hardhat (2 tabs)
npx hardhat nodeas per usualnpx hardhat deploy --network developmentas per usualAt this point Blockscout will start picking up the transactions
Todo:
Currently, contract verification is not working. This is as far as I've gotten:
I've debugged enough to confirm that the API is live, but for some reason the 2nd step (verifying with the full solc input) returns an HTML response, which breaks the verifier.
Resources:
https://hardhat.org/hardhat-runner/plugins/nomicfoundation-hardhat-verify
https://docs.blockscout.com/devs/verification/hardhat-verification-plugin
Blockscout's issue tracking proxy contract support