Closed kj-crypto closed 1 year ago
There would be also useful if compilerVersion
could accept such format: 0.8.13
. That simplifies param passing.
@kj-crypto I think you need to use /api?module=contract&action=verify
It allows do what you want. verifysourcecode
serves for verification via standard JSON input
About compiler versions such approach won't work since we can have different commits for one version of compiler. Also in such a case will be impossible to handle nighlty versions
Improve code parsing and endpoint params for
/api?module=contract&action=verifysourcecode
Environment
elixir -version
):1.12
4.1.2-beta
Expected behaviour
1. Allow
sourcecode
to beMap
Currently
sourcecode
accepts only encoded json string. It's better to passMap
without unnecessary nesting.2. Make arg params more verbose
It would be nice to unitize arg param keywords across other api endpoints e.q
module=contract&action=verifySourceCode&codeFormat={solidity-standard-json-input}&contractAddress={contractAddress}&contractName={contractName}&compilerVersion={compilerVersion}&sourceCode={sourceCode}
Current keywords likesourcecode={sourcecode}
it's not easily to interpret3. Add new lines in code formatting view to improve code readability
Add
<%= line <> "\n" %>
in following: https://github.com/blockscout/blockscout/blob/f67aaf85c0873035538e6200f5ac57caf41d81eb/apps/block_scout_web/lib/block_scout_web/templates/address_contract/index.html.eex#L106 https://github.com/blockscout/blockscout/blob/f67aaf85c0873035538e6200f5ac57caf41d81eb/apps/block_scout_web/lib/block_scout_web/templates/address_contract/index.html.eex#L119