ApeWorX / ape-etherscan

Etherscan explorer plugin using EVM-based networks for the Ape Framework
https://www.apeworx.io/
Apache License 2.0
21 stars 25 forks source link

fix: viaIR would not verify on etherscan #129

Open sreyemnayr opened 2 months ago

sreyemnayr commented 2 months ago

This was causing me to pull my hair out! It turns out that etherscan's single-file verification has no way to indicate that viaIR was used by the compiler. However, the standard json method DOES. I guess that historically, only ethereum supported this method, but now it appears that at least Base/Blast (only one's I've tested so far) do - but in any case, viaIR would ALWAYS cause failure in single-file mode. Now if single file mode is being used, it raises an exception explaining as much, and verifies otherwise.

What I did

fixes: #

How I did it

How to verify it

Verified contracts. What I don't know how to do is create actual tests for this beyond dogfood. To that end, I planned on generating a simple few contracts to deploy across several ecosystems.

Checklist

github-actions[bot] commented 1 month ago

This pull request is considered stale because it has been open 30 days with no activity. Remove stale label, add a comment, or make a new commit, otherwise this PR will be closed in 5 days.