forge script --verifier sourcify
is ignored when ETHERSCAN_API_KEY
env var is defined
#10000
Open
2 tasks done
Labels
A-verification
Area: verification
C-forge
Command: forge
Cmd-forge-script
Command: forge script
T-bug
Type: bug
Milestone
Component
Forge
Have you ensured that all of these are up to date?
What version of Foundry are you on?
forge Version: 1.0.0-stable
What version of Foundryup are you on?
foundryup: 0.3.1
What command(s) is the bug in?
forge script
Operating System
Linux
Describe the bug
We're trying to verify a contract on Sourcify, but the forge script attempts to verify on Etherscan instead. This only happens when the
ETHERSCAN_API_KEY
environment variable is defined. It's unexpected that the variable would take precedence over the--verifier sourcify
flag. When I delete the environment variable, Foundry correctly verifies against Sourcify.I set up a simple example repository to reproduce the issue at https://github.com/runtimeverification/buildbear-verifiy
This fails:
It looks like the error was introduced in this PR:
https://github.com/foundry-rs/foundry/pull/9630/files#diff-83809d8e219fe52b39eed2ae2f638def658f8a8d2121e298bf48cb8c39af6fdfR173
The text was updated successfully, but these errors were encountered: