Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions crates/verify/src/etherscan/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ impl VerificationProvider for EtherscanVerificationProvider {
.wrap_err_with(|| {
// valid json
let args = serde_json::to_string(&verify_args).unwrap();
error!(?args, "Failed to submit verification");
format!("Failed to submit contract verification, payload:\n{args}")
})?;

Expand All @@ -110,16 +109,16 @@ impl VerificationProvider for EtherscanVerificationProvider {
|| resp.result.starts_with("The address is not a smart contract")
{
warn!("{}", resp.result);
return Err(eyre!("Could not detect the deployment."));
return Err(eyre!("Could not detect deployment: {}", resp.result));
}

warn!("Failed verify submission: {:?}", resp);
sh_err!(
"Encountered an error verifying this contract:\nResponse: `{}`\nDetails:
`{}`",
resp.message,
resp.result
)?;
warn!("Failed verify submission: {:?}", resp);
std::process::exit(1);
}

Expand Down Expand Up @@ -186,7 +185,11 @@ impl VerificationProvider for EtherscanVerificationProvider {
}

if resp.status == "0" {
return Err(RetryError::Break(eyre!("Contract failed to verify.")));
return Err(RetryError::Break(eyre!(
"Contract verification failed:\nStatus: `{}`\nResult: `{}`",
resp.status,
resp.result
)));
}

if resp.result == "Pass - Verified" {
Expand Down
Loading